Home
last modified time | relevance | path

Searched refs:cfg (Results 1 – 25 of 58) sorted by relevance

123

/tools/asuite/aidegen/lib/
Dconfig_unittest.py63 cfg = config.AidegenConfig()
64 cfg._load_aidegen_config()
68 cfg = config.AidegenConfig()
69 cfg._load_aidegen_config()
81 cfg = config.AidegenConfig()
84 cfg._load_aidegen_config()
89 cfg._load_aidegen_config()
99 cfg = config.AidegenConfig()
100 cfg._save_aidegen_config()
111 cfg = config.AidegenConfig()
[all …]
/tools/acloud/public/
Dconfig_test.py120 cfg = config.AcloudConfigManager.LoadConfigFromProtocolBuffer(
122 self.assertEqual(cfg.service_account_name,
124 self.assertEqual(cfg.service_account_private_key_path,
126 self.assertEqual(cfg.service_account_json_private_key_path,
128 self.assertEqual(cfg.project, "fake-project")
129 self.assertEqual(cfg.zone, "us-central1-f")
130 self.assertEqual(cfg.machine_type, "n1-standard-1")
131 self.assertEqual(cfg.network, "default")
132 self.assertEqual(cfg.ssh_private_key_path, "/path/to/ssh/key")
133 self.assertEqual(cfg.storage_bucket_name, "fake_bucket")
[all …]
Ddevice_driver.py58 def __init__(self, cfg, devices=None): argument
60 self._cfg = cfg
61 credentials = auth.CreateCredentials(cfg)
66 cfg, credentials)
337 def CreateGCETypeAVD(cfg, argument
373 credentials = auth.CreateCredentials(cfg)
374 compute_client = android_compute_client.AndroidComputeClient(cfg,
377 common_operations.CreateSshKeyPairIfNecessary(cfg)
378 device_pool = AndroidVirtualDevicePool(cfg)
386 extra_data_disk_size_gb=cfg.extra_data_disk_size_gb,
[all …]
Ddevice_driver_test.py35 cfg = mock.MagicMock()
36 cfg.service_account_name = "fake@service.com"
37 cfg.service_account_private_key_path = "/fake/path/to/key"
38 cfg.zone = "fake_zone"
39 cfg.disk_image_name = "fake_image.tar.gz"
40 cfg.disk_image_mime_type = "fake/type"
41 cfg.storage_bucket_name = "fake_bucket"
42 cfg.extra_data_disk_size_gb = 4
43 cfg.precreated_data_image_map = {
47 cfg.extra_scopes = None
[all …]
/tools/treble/build/sandbox/
Dconfig_test.py84 cfg = config.factory(None)
85 self.assertIsNone(cfg)
91 cfg = config.factory(test_config.name)
93 cfg.get_available_build_targets(),
107 cfg = config.factory(test_config.name)
109 self.assertSetEqual(cfg.get_tags('android_target_1'), set())
111 cfg.get_tags('android_target_2'), set(['cool', 'hot', 'warm']))
113 cfg.get_tags('build_target_2'), set(['cool', 'hot', 'dry']))
114 self.assertSetEqual(cfg.get_tags('android_target_3'), set())
116 self.assertFalse(cfg.has_tag('android_target_1', 'cool'))
[all …]
Doverlay_test.py97 cfg=config.factory(test_config.name),
130 cfg=config.factory(test_config.name),
154 cfg=config.factory(test_config.name),
186 cfg=config.factory(test_config.name),
218 cfg=config.factory(test_config.name),
247 cfg=config.factory(test_config.name),
275 cfg=config.factory(test_config.name),
300 cfg=config.factory(test_config.name),
Dbuild_android_sandboxed.py53 cfg = config.Config(config_file)
54 android_target = cfg.get_build_config_android_target(build_target)
55 if cfg.has_tag(build_target, 'skip'):
192 cfg = config.Config(args['config_file'])
193 build_goals = cfg.get_build_goals(args['build_target'], set(args['context']))
/tools/acloud/public/actions/
Dcreate_goldfish_action.py63 cfg, argument
93 self.credentials = auth.CreateCredentials(cfg)
96 cfg, self.credentials)
100 self._cfg = cfg
103 self._blank_data_disk_size_gb = cfg.extra_data_disk_size_gb
104 self._extra_scopes = cfg.extra_scopes
117 kernel_build_target or cfg.kernel_build_target, kernel_build_id,
201 def _FetchBuildIdFromFile(cfg, build_target, build_id, filename): argument
217 auth.CreateCredentials(cfg))
231 cfg=None, argument
[all …]
Dcreate_cuttlefish_action_test.py81 cfg = mock.MagicMock()
82 cfg.service_account_name = "fake@service.com"
83 cfg.service_account_private_key_path = "/fake/path/to/key"
84 cfg.zone = "fake_zone"
85 cfg.disk_image_name = "fake_image.tar.gz"
86 cfg.disk_image_mime_type = "fake/type"
87 cfg.ssh_private_key_path = ""
88 cfg.ssh_public_key_path = ""
89 cfg.stable_host_image_name = self.STABLE_HOST_IMAGE_NAME
90 cfg.stable_host_image_project = self.STABLE_HOST_IMAGE_PROJECT
[all …]
Dcreate_goldfish_action_test.py72 self.avd_spec.cfg = self._CreateCfg()
83 cfg = mock.MagicMock()
84 cfg.service_account_name = "fake@service.com"
85 cfg.service_account_private_key_path = "/fake/path/to/key"
86 cfg.zone = "fake_zone"
87 cfg.ssh_private_key_path = ""
88 cfg.ssh_public_key_path = ""
89 cfg.stable_goldfish_host_image_name = self.GOLDFISH_HOST_IMAGE_NAME
90 cfg.stable_goldfish_host_image_project = self.GOLDFISH_HOST_IMAGE_PROJECT
91 cfg.emulator_build_target = self.EMULATOR_BUILD_TARGET
[all …]
Dcommon_operations_test.py82 cfg = mock.MagicMock()
83 cfg.service_account_name = "fake@service.com"
84 cfg.service_account_private_key_path = "/fake/path/to/key"
85 cfg.zone = "fake_zone"
86 cfg.disk_image_name = "fake_image.tar.gz"
87 cfg.disk_image_mime_type = "fake/type"
88 cfg.ssh_private_key_path = ""
89 cfg.ssh_public_key_path = ""
90 return cfg
101 cfg = self._CreateCfg()
[all …]
Dcommon_operations.py37 def CreateSshKeyPairIfNecessary(cfg): argument
46 if not cfg.ssh_public_key_path:
54 elif cfg.ssh_public_key_path and not cfg.ssh_private_key_path:
60 elif cfg.ssh_public_key_path and cfg.ssh_private_key_path:
61 utils.CreateSshKeyPairIfNotExist(cfg.ssh_private_key_path,
62 cfg.ssh_public_key_path)
176 def CreateDevices(command, cfg, device_factory, num, avd_type, argument
212 CreateSshKeyPairIfNecessary(cfg)
247 rsa_key_file=cfg.ssh_private_key_path,
252 extra_args_ssh_tunnel=cfg.extra_args_ssh_tunnel)
[all …]
Dcreate_cuttlefish_action.py54 def __init__(self, cfg, build_target, build_id, branch=None, argument
61 self.credentials = auth.CreateCredentials(cfg)
63 if cfg.enable_multi_stage:
65 cfg, self.credentials, boot_timeout_secs, ins_timeout_secs,
69 cfg, self.credentials)
73 self._cfg = cfg
78 self._blank_data_disk_size_gb = cfg.extra_data_disk_size_gb
79 self._extra_scopes = cfg.extra_scopes
89 kernel_build_target or cfg.kernel_build_target, kernel_build_id,
189 def CreateDevices(cfg, argument
[all …]
Dremote_instance_cf_device_factory_test.py107 fake_avd_spec.cfg.enable_multi_stage = True
151 fake_avd_spec.cfg.enable_multi_stage = True
183 fake_avd_spec.cfg.enable_multi_stage = True
369 fake_avd_spec.cfg = mock.MagicMock()
387 mock.call(fake_avd_spec.cfg, build_target, build_id, checkfile1,
389 mock.call(fake_avd_spec.cfg, build_target, build_id, checkfile2,
/tools/acloud/delete/
Ddelete.py47 def DeleteInstances(cfg, instances_to_delete): argument
83 return DeleteRemoteInstances(cfg, remote_instance_list, delete_report)
91 def DeleteRemoteInstances(cfg, instances_to_delete, delete_report=None): argument
105 if not cfg.SupportRemoteInstance():
119 cfg, instances_to_delete, delete_report)
181 def CleanUpRemoteHost(cfg, remote_host, host_user, argument
196 credentials = auth.CreateCredentials(cfg)
198 acloud_config=cfg,
204 host_ssh_private_key_path or cfg.ssh_private_key_path))
219 def DeleteInstanceByNames(cfg, instances): argument
[all …]
/tools/acloud/list/
Dlist.py108 def GetRemoteInstances(cfg): argument
119 credentials = auth.CreateCredentials(cfg)
120 compute_client = gcompute_client.ComputeClient(cfg, credentials)
185 def GetInstances(cfg): argument
194 return GetRemoteInstances(cfg) + GetLocalInstances()
212 def ChooseInstances(cfg, select_all_instances=False): argument
226 instances = GetInstances(cfg)
232 def ChooseOneRemoteInstance(cfg): argument
247 instances_list = GetCFRemoteInstances(cfg)
289 def GetInstancesFromInstanceNames(cfg, instance_names): argument
[all …]
Dlist_test.py40 cfg = mock.MagicMock()
49 instances_list = list_instance.GetInstancesFromInstanceNames(cfg, instance_names)
54 instances_list = list_instance.GetInstancesFromInstanceNames(cfg, instance_names)
65 cfg=cfg,
70 cfg = mock.MagicMock()
76 self.assertEqual(list_instance.ChooseOneRemoteInstance(cfg), expected_instance)
81 list_instance.ChooseOneRemoteInstance(cfg)
89 self.assertEqual(list_instance.ChooseOneRemoteInstance(cfg), expected_instance)
/tools/acloud/setup/
Dgcp_setup_runner.py256 cfg = config_mgr.Load()
258 self.project = cfg.project
259 self.zone = cfg.zone
260 self.ssh_private_key_path = cfg.ssh_private_key_path
261 self.ssh_public_key_path = cfg.ssh_public_key_path
262 self.stable_host_image_name = cfg.stable_host_image_name
263 self.client_id = cfg.client_id
264 self.client_secret = cfg.client_secret
265 self.service_account_name = cfg.service_account_name
266 self.service_account_private_key_path = cfg.service_account_private_key_path
[all …]
Dgcp_setup_runner_test.py75 cfg = config.AcloudConfigManager.LoadConfigFromProtocolBuffer(
77 self.assertEqual(cfg.project, "test_project")
78 self.assertEqual(cfg.ssh_private_key_path, "")
82 cfg = config.AcloudConfigManager.LoadConfigFromProtocolBuffer(
84 self.assertEqual(cfg.project, "test_project")
85 self.assertEqual(cfg.ssh_private_key_path, "test_path")
91 cfg = config.AcloudConfigManager.LoadConfigFromProtocolBuffer(
93 self.assertEqual(cfg.project, "test_project")
/tools/acloud/create/
Dcheeps_remote_image_remote_instance_test.py59 cfg = mock.MagicMock()
60 cfg.service_account_name = "fake@service.com"
61 cfg.service_account_private_key_path = "/fake/path/to/key"
62 cfg.zone = "fake_zone"
63 cfg.ssh_private_key_path = ""
64 cfg.ssh_public_key_path = ""
65 cfg.stable_cheeps_host_image_name = self.CHEEPS_HOST_IMAGE_NAME
66 cfg.stable_cheeps_host_image_project = self.CHEEPS_HOST_IMAGE_PROJECT
67 return cfg
72 avd_spec.cfg = self._CreateCfg()
Dcheeps_remote_image_remote_instance.py50 avd_spec.cfg.project, avd_spec.remote_image[constants.BUILD_ID])
52 device_factory = CheepsDeviceFactory(avd_spec.cfg, avd_spec)
56 cfg=avd_spec.cfg,
81 def __init__(self, cfg, avd_spec=None): argument
88 self.credentials = auth.CreateCredentials(cfg)
91 cfg, self.credentials)
94 self._cfg = cfg
/tools/acloud/reconnect/
Dreconnect.py122 def AddPublicSshRsaToInstance(cfg, user, instance_name): argument
132 credentials = auth.CreateCredentials(cfg)
134 cfg, credentials)
137 cfg.ssh_public_key_path,
239 cfg = config.GetAcloudConfig(args)
244 cfg, args.instance_names)
246 instances_to_reconnect = list_instance.ChooseInstances(cfg, args.all)
257 AddPublicSshRsaToInstance(cfg, constants.GCE_USER, instance.name)
258 ReconnectInstance(cfg.ssh_private_key_path,
261 cfg.extra_args_ssh_tunnel,
/tools/acloud/pull/
Dpull_test.py37 cfg = mock.MagicMock()
38 cfg.ssh_private_key_path = "fake_ssh_path"
39 cfg.extra_args_ssh_tunnel = ""
48 pull.PullFileFromInstance(cfg, instance)
54 pull.PullFileFromInstance(cfg, instance)
144 cfg = mock.MagicMock()
151 self.Patch(config, "GetAcloudConfig", return_value=cfg)
156 mock.call(cfg, instance_obj, args.file_name, args.no_prompt)])
165 mock.call(cfg, selected_instance, args.file_name, args.no_prompt)])
Dpull.py43 def PullFileFromInstance(cfg, instance, file_name=None, no_prompts=False): argument
61 ssh_private_key_path=cfg.ssh_private_key_path,
62 extra_args_ssh_tunnel=cfg.extra_args_ssh_tunnel)
215 cfg = config.GetAcloudConfig(args)
218 cfg, [args.instance_name])
219 return PullFileFromInstance(cfg, instance[0], args.file_name, args.no_prompt)
220 return PullFileFromInstance(cfg,
221 list_instances.ChooseOneRemoteInstance(cfg),
/tools/test/connectivity/acts/framework/acts/test_utils/tel/
Dtwilio_client.py56 cfg = yaml.load(cfg_file)
57 self.__account_sid = cfg[ACCOUNT_SID_KEY]
58 self.__auth_token = cfg[AUTH_TOKEN_KEY]
59 self.__phone_number = cfg[PHONE_NUMBER_KEY]
60 self.urls = cfg[URLS_KEY]

123