How to use google method in locust

Best Python code snippet using locust

protobuf.gyp

Source:protobuf.gyp Github

copy

Full Screen

1# Copyright 2014 The Chromium Authors. All rights reserved.2# Use of this source code is governed by a BSD-style license that can be3# found in the LICENSE file.4{5 'targets': [6 {7 'target_name': 'protobuf_lite',8 'type': 'none',9 'direct_dependent_settings': {10 'cflags': [11 # Use full protobuf, because vanilla protobuf doesn't have12 # our custom patch to retain unknown fields in lite mode.13 '<!@(pkg-config --cflags protobuf)',14 ],15 'defines': [16 'USE_SYSTEM_PROTOBUF',17 # This macro must be defined to suppress the use18 # of dynamic_cast<>, which requires RTTI.19 'GOOGLE_PROTOBUF_NO_RTTI',20 'GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER',21 ],22 },23 'link_settings': {24 # Use full protobuf, because vanilla protobuf doesn't have25 # our custom patch to retain unknown fields in lite mode.26 'ldflags': [27 '<!@(pkg-config --libs-only-L --libs-only-other protobuf)',28 ],29 'libraries': [30 '<!@(pkg-config --libs-only-l protobuf)',31 ],32 },33 'variables': {34 'headers_root_path': 'src',35 'header_filenames': [36 # This list can easily be updated using the command below:37 # find third_party/protobuf/src -iname '*.h' -printf "'%p',\n" | \38 # sed -e 's|third_party/protobuf/src/||' | sort -u39 'google/protobuf/compiler/code_generator.h',40 'google/protobuf/compiler/command_line_interface.h',41 'google/protobuf/compiler/cpp/cpp_enum_field.h',42 'google/protobuf/compiler/cpp/cpp_enum.h',43 'google/protobuf/compiler/cpp/cpp_extension.h',44 'google/protobuf/compiler/cpp/cpp_field.h',45 'google/protobuf/compiler/cpp/cpp_file.h',46 'google/protobuf/compiler/cpp/cpp_generator.h',47 'google/protobuf/compiler/cpp/cpp_helpers.h',48 'google/protobuf/compiler/cpp/cpp_message_field.h',49 'google/protobuf/compiler/cpp/cpp_message.h',50 'google/protobuf/compiler/cpp/cpp_options.h',51 'google/protobuf/compiler/cpp/cpp_primitive_field.h',52 'google/protobuf/compiler/cpp/cpp_service.h',53 'google/protobuf/compiler/cpp/cpp_string_field.h',54 'google/protobuf/compiler/cpp/cpp_unittest.h',55 'google/protobuf/compiler/importer.h',56 'google/protobuf/compiler/java/java_doc_comment.h',57 'google/protobuf/compiler/java/java_enum_field.h',58 'google/protobuf/compiler/java/java_enum.h',59 'google/protobuf/compiler/java/java_extension.h',60 'google/protobuf/compiler/java/java_field.h',61 'google/protobuf/compiler/java/java_file.h',62 'google/protobuf/compiler/java/java_generator.h',63 'google/protobuf/compiler/java/java_helpers.h',64 'google/protobuf/compiler/java/java_message_field.h',65 'google/protobuf/compiler/java/java_message.h',66 'google/protobuf/compiler/java/java_primitive_field.h',67 'google/protobuf/compiler/java/java_service.h',68 'google/protobuf/compiler/java/java_string_field.h',69 'google/protobuf/compiler/mock_code_generator.h',70 'google/protobuf/compiler/package_info.h',71 'google/protobuf/compiler/parser.h',72 'google/protobuf/compiler/plugin.h',73 'google/protobuf/compiler/plugin.pb.h',74 'google/protobuf/compiler/python/python_generator.h',75 'google/protobuf/compiler/subprocess.h',76 'google/protobuf/compiler/zip_writer.h',77 'google/protobuf/descriptor_database.h',78 'google/protobuf/descriptor.h',79 'google/protobuf/descriptor.pb.h',80 'google/protobuf/dynamic_message.h',81 'google/protobuf/extension_set.h',82 'google/protobuf/generated_enum_reflection.h',83 'google/protobuf/generated_message_reflection.h',84 'google/protobuf/generated_message_util.h',85 'google/protobuf/io/coded_stream.h',86 'google/protobuf/io/coded_stream_inl.h',87 'google/protobuf/io/gzip_stream.h',88 'google/protobuf/io/package_info.h',89 'google/protobuf/io/printer.h',90 'google/protobuf/io/tokenizer.h',91 'google/protobuf/io/zero_copy_stream.h',92 'google/protobuf/io/zero_copy_stream_impl.h',93 'google/protobuf/io/zero_copy_stream_impl_lite.h',94 'google/protobuf/message.h',95 'google/protobuf/message_lite.h',96 'google/protobuf/package_info.h',97 'google/protobuf/reflection_ops.h',98 'google/protobuf/repeated_field.h',99 'google/protobuf/service.h',100 'google/protobuf/stubs/atomicops.h',101 'google/protobuf/stubs/atomicops_internals_arm64_gcc.h',102 'google/protobuf/stubs/atomicops_internals_arm_gcc.h',103 'google/protobuf/stubs/atomicops_internals_arm_qnx.h',104 'google/protobuf/stubs/atomicops_internals_atomicword_compat.h',105 'google/protobuf/stubs/atomicops_internals_macosx.h',106 'google/protobuf/stubs/atomicops_internals_mips_gcc.h',107 'google/protobuf/stubs/atomicops_internals_pnacl.h',108 'google/protobuf/stubs/atomicops_internals_tsan.h',109 'google/protobuf/stubs/atomicops_internals_x86_gcc.h',110 'google/protobuf/stubs/atomicops_internals_x86_msvc.h',111 'google/protobuf/stubs/common.h',112 'google/protobuf/stubs/hash.h',113 'google/protobuf/stubs/map-util.h',114 'google/protobuf/stubs/once.h',115 'google/protobuf/stubs/platform_macros.h',116 'google/protobuf/stubs/stl_util.h',117 'google/protobuf/stubs/stringprintf.h',118 'google/protobuf/stubs/strutil.h',119 'google/protobuf/stubs/substitute.h',120 'google/protobuf/stubs/template_util.h',121 'google/protobuf/stubs/type_traits.h',122 'google/protobuf/testing/file.h',123 'google/protobuf/testing/googletest.h',124 'google/protobuf/test_util.h',125 'google/protobuf/test_util_lite.h',126 'google/protobuf/text_format.h',127 'google/protobuf/unknown_field_set.h',128 'google/protobuf/wire_format.h',129 'google/protobuf/wire_format_lite.h',130 'google/protobuf/wire_format_lite_inl.h',131 ],132 },133 'includes': [134 '../../build/shim_headers.gypi',135 ],136 },137 {138 'target_name': 'protoc',139 'type': 'none',140 'toolsets': ['host', 'target'],141 },142 {143 'target_name': 'py_proto',144 'type': 'none',145 },146 ],...

Full Screen

Full Screen

__init__.py

Source:__init__.py Github

copy

Full Screen

1"""2 This module houses the GoogleMap object, used for generating3 the needed javascript to embed Google Maps in a Web page.45 Google(R) is a registered trademark of Google, Inc. of Mountain View, California.67 Example:89 * In the view:10 return render_to_response('template.html', {'google' : GoogleMap(key="abcdefg")})1112 * In the template:1314 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">15 {{ google.xhtml }}16 <head>17 <title>Google Maps via GeoDjango</title>18 {{ google.style }}19 {{ google.scripts }}20 </head>21 {{ google.body }}22 <div id="{{ google.dom_id }}" style="width:600px;height:400px;"></div>23 </body>24 </html>2526 Note: If you want to be more explicit in your templates, the following are27 equivalent:28 {{ google.body }} => "<body {{ google.onload }} {{ google.onunload }}>"29 {{ google.xhtml }} => "<html xmlns="http://www.w3.org/1999/xhtml" {{ google.xmlns }}>"30 {{ google.style }} => "<style>{{ google.vml_css }}</style>"3132 Explanation:33 - The `xhtml` property provides the correct XML namespace needed for 34 Google Maps to operate in IE using XHTML. Google Maps on IE uses35 VML to draw polylines. Returns, by default: 36 <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml">37 38 - The `style` property provides the correct style tag for the CSS39 properties required by Google Maps on IE:40 <style type="text/css">v\:* {behavior:url(#default#VML);}</style>4142 - The `scripts` property provides the necessary <script> tags for 43 including the Google Maps javascript, as well as including the44 generated javascript.4546 - The `body` property provides the correct attributes for the 47 body tag to load the generated javascript. By default, returns:48 <body onload="gmap_load()" onunload="GUnload()">4950 - The `dom_id` property returns the DOM id for the map. Defaults to "map".5152 The following attributes may be set or customized in your local settings:53 * GOOGLE_MAPS_API_KEY: String of your Google Maps API key. These are tied to54 to a domain. May be obtained from http://www.google.com/apis/maps/55 * GOOGLE_MAPS_API_VERSION (optional): Defaults to using "2.x"56 * GOOGLE_MAPS_URL (optional): Must have a substitution ('%s') for the API57 version.58"""59from django.contrib.gis.maps.google.gmap import GoogleMap, GoogleMapSet60from django.contrib.gis.maps.google.overlays import GEvent, GIcon, GMarker, GPolygon, GPolyline ...

Full Screen

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run locust automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful