/tools/acloud/internal/lib/ |
D | utils_test.py | 34 from acloud.internal.lib import utils 71 with utils.TempDir(): 87 with utils.TempDir(): 104 with utils.TempDir(): 122 with utils.TempDir(): 141 with utils.TempDir(): 158 utils.CreateSshKeyPairIfNotExist(private_key, public_key) 169 utils.CreateSshKeyPairIfNotExist(private_key, public_key) 172 utils.SSH_KEYGEN_CMD + 187 utils.CreateSshKeyPairIfNotExist(private_key, public_key) [all …]
|
D | adb_tools.py | 21 from acloud.internal.lib import utils 92 self._adb_command = utils.FindExecutable(constants.ADB_BIN) 148 device_info = utils.CheckOutput(adb_cmd) 201 utils.PrintColorString("Failed to adb disconnect %s" % 203 utils.TextColors.FAIL) 216 utils.RetryExceptionType(exception_types=errors.AdbDisconnectFailed, 236 utils.PrintColorString("Failed to adb connect %s" % 238 utils.TextColors.FAIL) 251 utils.PrintColorString("Failed to unlock screen." 253 utils.TextColors.WARNING)
|
D | cvd_compute_client_multi_stage.py | 51 from acloud.internal.lib import utils 356 @utils.TimeExecute(function_description="Launching AVD(s) and waiting for boot up", 357 result_evaluator=utils.BootEvaluator) 397 utils.PrintColorString(str(e), utils.TextColors.FAIL) 418 @utils.TimeExecute(function_description="Reusing GCE instance") 436 @utils.TimeExecute(function_description="Creating GCE instance") 488 @utils.TimeExecute(function_description="Uploading build fetcher to instance") 500 utils.RetryExceptionType( 505 retry_backoff_factor=utils.DEFAULT_RETRY_BACKOFF_FACTOR, 517 @utils.TimeExecute(function_description="Downloading build on instance")
|
/tools/test/connectivity/acts_tests/tests/google/fuchsia/wlan/ |
D | SoftApTest.py | 21 from acts import utils 495 'ssid': utils.rand_ascii_str( 505 'ssid': utils.rand_ascii_str( 515 'ssid': utils.rand_ascii_str( 526 utils.rand_ascii_str(hostapd_constants.AP_SSID_LENGTH_2G), 530 utils.rand_ascii_str(hostapd_constants.MIN_WPA_PSK_LENGTH), 541 utils.rand_ascii_str(hostapd_constants.AP_SSID_LENGTH_5G), 545 utils.rand_ascii_str(hostapd_constants.MIN_WPA_PSK_LENGTH), 556 utils.rand_ascii_str(hostapd_constants.AP_SSID_LENGTH_5G), 560 utils.rand_ascii_str(hostapd_constants.MIN_WPA_PSK_LENGTH), [all …]
|
D | WlanPhyComplianceABGTest.py | 17 from acts import utils 235 wmm_acm_bits_enabled = utils.merge_dicts( 248 wmm_acm_bits_enabled = utils.merge_dicts( 261 wmm_acm_bits_enabled = utils.merge_dicts( 274 wmm_acm_bits_enabled = utils.merge_dicts( 287 wmm_acm_bits_enabled = utils.merge_dicts( 301 wmm_acm_bits_enabled = utils.merge_dicts( 315 wmm_acm_bits_enabled = utils.merge_dicts( 329 wmm_acm_bits_enabled = utils.merge_dicts( 343 country_info = utils.merge_dicts( [all …]
|
/tools/acloud/reconnect/ |
D | reconnect_test.py | 25 from acloud.internal.lib import utils 49 self.Patch(utils, "LaunchVncClient") 50 self.Patch(utils, "AutoConnect") 53 self.Patch(utils, "IsCommandRunning", return_value=False) 65 utils.AutoConnect.call_count = 0 67 utils.AutoConnect.assert_not_called() 68 utils.LaunchVncClient.assert_called_with(6666) 72 utils.AutoConnect.call_count = 0 74 utils.AutoConnect.assert_not_called() 75 utils.LaunchVncClient.assert_called_with(6666, "888", "777") [all …]
|
D | reconnect.py | 31 from acloud.internal.lib import utils 44 [utils.PORT_MAPPING % {"local_port":port["local"], 46 for port in utils.WEBRTC_PORTS_MAPPING]) 91 process_output = utils.CheckOutput(constants.COMMAND_PS) 111 if not utils.IsCommandRunning(vnc_started_pattern): 113 utils.CleanupSSVncviewer(vnc_port) 117 utils.LaunchVncClient(vnc_port, match.group(1), match.group(2)) 119 utils.LaunchVncClient(vnc_port) 141 @utils.TimeExecute(function_description="Reconnect instances") 167 if instance.avd_type not in utils.AVD_PORT_DICT: [all …]
|
/tools/test/connectivity/acts/framework/tests/ |
D | acts_utils_test.py | 23 from acts import utils 177 with self.assertRaisesRegex(utils.ActsUtilsError, 179 utils.start_standing_subprocess('sleep 0', check_health_delay=0.1) 182 p = utils.start_standing_subprocess('sleep 0') 184 with self.assertRaisesRegex(utils.ActsUtilsError, 186 utils.stop_standing_subprocess(p) 198 self.assertTrue(utils.bypass_setup_wizard(ad)) 214 utils.bypass_setup_wizard(ad) 232 utils.bypass_setup_wizard(ad) 250 self.assertTrue(utils.bypass_setup_wizard(ad)) [all …]
|
/tools/repohooks/rh/ |
D | utils_unittest.py | 35 import rh.utils 44 self.assertEqual('0.000s', rh.utils.timedelta_str(delta)) 49 self.assertEqual('0.123s', rh.utils.timedelta_str(delta)) 54 self.assertEqual('12.300s', rh.utils.timedelta_str(delta)) 59 self.assertEqual('1m12.300s', rh.utils.timedelta_str(delta)) 64 self.assertEqual('1h6m40.300s', rh.utils.timedelta_str(delta)) 72 result = rh.utils.CompletedProcess(args=[]) 77 result = rh.utils.CompletedProcess(args=['ls', 'a b']) 83 result = rh.utils.CompletedProcess() 85 result = rh.utils.CompletedProcess(args=[]) [all …]
|
D | git.py | 30 import rh.utils 37 result = rh.utils.run(cmd, capture_output=True) 42 result = rh.utils.run(cmd, capture_output=True) 53 result = rh.utils.run(cmd, capture_output=True) 60 result = rh.utils.run(cmd, capture_output=True) 66 result = rh.utils.run(cmd, capture_output=True) 77 result = rh.utils.run(cmd, capture_output=True) 92 return rh.utils.run(cmd, capture_output=True).stdout 106 return rh.utils.run(cmd, capture_output=True).stdout 148 diff = rh.utils.run(cmd, cwd=path, capture_output=True).stdout [all …]
|
/tools/acloud/create/ |
D | avd_spec.py | 36 from acloud.internal.lib import utils 402 local_image_dir = utils.GetBuildEnvironmentVariable( 432 utils.GetBuildEnvironmentVariable( 458 local_image_path = utils.GetBuildEnvironmentVariable( 469 utils.PrintColorString(_LOCAL_ZIP_WARNING_MSG, 470 utils.TextColors.WARNING) 483 utils.GetBuildEnvironmentVariable(constants.ENV_BUILD_TARGET)) 497 build_target = utils.GetBuildEnvironmentVariable( 500 utils.PrintColorString( 503 utils.TextColors.WARNING) [all …]
|
D | base_avd_create.py | 22 from acloud.internal.lib import utils 46 utils.PrintDeviceSummary(results) 66 utils.PrintColorString( 70 utils.PrintColorString("Image (local):") 71 utils.PrintColorString(" %s" % (avd_spec.local_image_dir or 74 utils.PrintColorString("Image:") 75 utils.PrintColorString( 80 utils.PrintColorString("hw config:") 81 utils.PrintColorString(" cpu - %s" % (avd_spec.hw_property[constants.HW_ALIAS_CPUS])) 82 utils.PrintColorString(" ram - %dGB" % ( [all …]
|
D | create.py | 43 from acloud.internal.lib import utils 122 if not args.autoconnect or utils.FindExecutable(constants.ADB_BIN): 126 answer = _YES if args.no_prompt else utils.InteractWithQuestion( 130 utils.PrintColorString("Building adb ... ", end="") 134 utils.PrintColorString("Fail! (Not in a lunch'd env)", 135 utils.TextColors.FAIL) 144 utils.PrintColorString("OK!", utils.TextColors.OKGREEN) 146 utils.PrintColorString("Fail! (build failed)", 147 utils.TextColors.FAIL) 153 utils.PrintColorString("Disabling autoconnect", [all …]
|
D | local_image_local_instance.py | 47 from acloud.internal.lib import utils 80 @utils.TimeExecute(function_description="Total time: ", 96 if not utils.IsSupportedPlatform(print_warning=True): 135 utils.LaunchVNCFromReport(result_report, avd_spec, no_prompts) 137 utils.LaunchBrowserFromReport(result_report) 220 launch_cmd = utils.AddUserGroupsToCmd(launch_cvd_w_args, 250 if no_prompts or utils.GetUserAnswerYes(_CONFIRM_RELAUNCH % 260 utils.PrintColorString( 264 utils.TextColors.FAIL) 267 utils.ReleasePort(constants.WEBRTC_LOCAL_PORT) [all …]
|
D | avd_spec_test.py | 28 from acloud.internal.lib import utils 66 self.Patch(utils, "GetBuildEnvironmentVariable", 77 self.Patch(utils, "GetBuildEnvironmentVariable", 84 self.Patch(utils, "GetBuildEnvironmentVariable", 94 self.Patch(utils, "GetBuildEnvironmentVariable", 235 @mock.patch.object(utils, "PrintColorString") 239 self.Patch(utils, "GetBuildEnvironmentVariable", 244 self.Patch(utils, "GetBuildEnvironmentVariable", 248 self.Patch(utils, "GetBuildEnvironmentVariable",
|
/tools/acloud/delete/ |
D | delete.py | 31 from acloud.internal.lib import utils 77 utils.CleanupSSVncviewer(instance.vnc_port) 88 @utils.TimeExecute(function_description="Deleting remote instances", 89 result_evaluator=utils.ReportEvaluator, 109 utils.PrintColorString("") 111 utils.PrintColorString(" - %s" % instance, utils.TextColors.WARNING) 112 utils.PrintColorString("") 113 utils.PrintColorString("status: waiting...", end="") 124 @utils.TimeExecute(function_description="Deleting local cuttlefish instances", 125 result_evaluator=utils.ReportEvaluator) [all …]
|
/tools/test/connectivity/acts/framework/acts/test_utils/wifi/ |
D | WifiBaseTest.py | 28 from acts import utils 83 ref_2g_ssid = 'xg_%s' % utils.rand_ascii_str(ssid_length_2g) 86 ref_2g_passphrase = utils.rand_ascii_str(passphrase_length_2g) 90 ref_2g_ssid = '2g_%s' % utils.rand_ascii_str(ssid_length_2g) 91 ref_2g_passphrase = utils.rand_ascii_str(passphrase_length_2g) 93 ref_5g_ssid = '5g_%s' % utils.rand_ascii_str(ssid_length_5g) 94 ref_5g_passphrase = utils.rand_ascii_str(passphrase_length_5g) 145 open_2g_ssid = 'xg_%s' % utils.rand_ascii_str(ssid_length_2g) 149 open_2g_ssid = '2g_%s' % utils.rand_ascii_str(ssid_length_2g) 150 open_5g_ssid = '5g_%s' % utils.rand_ascii_str(ssid_length_5g) [all …]
|
/tools/test/connectivity/acts/framework/acts/test_utils/wifi/p2p/ |
D | WifiP2pBaseTest.py | 17 import acts.utils 22 from acts import utils 39 acts.utils.set_location_service(self.dut1, True) 40 acts.utils.set_location_service(self.dut2, True) 43 utils.sync_device_time(self.dut1) 51 utils.sync_device_time(self.dut2) 61 acts.utils.set_location_service(self.dut3, True) 63 utils.sync_device_time(self.dut3) 75 acts.utils.set_location_service(self.dut1, False) 76 acts.utils.set_location_service(self.dut2, False) [all …]
|
/tools/test/connectivity/acts/tests/google/wifi/ |
D | WifiSoftApTest.py | 23 from acts import utils 59 utils.require_sl4a((self.dut, self.dut_client)) 60 utils.sync_device_time(self.dut) 61 utils.sync_device_time(self.dut_client) 78 utils.sync_device_time(self.android_devices[2]) 98 asserts.assert_true(utils.force_airplane_mode(self.dut, False), 110 ap_ssid = "softap_" + utils.rand_ascii_str(8) 111 ap_password = utils.rand_ascii_str(8) 237 utils.adb_shell_ping(self.dut, count=10, dest_ip=dut_client_ip, timeout=20), 242 utils.adb_shell_ping(self.dut_client, count=10, dest_ip=dut_ip, timeout=20), [all …]
|
D | WifiStaApConcurrencyTest.py | 29 import acts.utils as utils namespace 58 utils.require_sl4a(self.android_devices) 62 utils.sync_device_time(ad) 124 utils.set_location_service(self.dut, True) 131 utils.set_location_service(self.dut, False) 156 ap_ssid = "softap_" + utils.rand_ascii_str(8) 157 ap_password = utils.rand_ascii_str(8) 255 if utils.adb_shell_ping(ad1, count=10, dest_ip=ad2_ip, timeout=20): 260 if utils.adb_shell_ping(ad2, count=10, dest_ip=ad1_ip, timeout=20):
|
/tools/acloud/public/ |
D | device_driver.py | 43 from acloud.internal.lib import utils 68 @utils.TimeExecute("Creating GCE image") 84 disk_image_id = utils.GenerateUniqueName( 104 @utils.TimeExecute("Creating GCE image") 126 with utils.TempDir() as tempdir: 130 utils.MakeTarFile( 140 disk_image_id = utils.GenerateUniqueName( 252 @utils.TimeExecute("Waiting for AVD to boot") 323 with utils.TempDir() as tempdir: 333 utils.MakeTarFile(src_dict, output_file) [all …]
|
/tools/acloud/public/actions/ |
D | common_operations.py | 30 from acloud.internal.lib import utils 61 utils.CreateSshKeyPairIfNotExist(cfg.ssh_private_key_path, 107 @utils.TimeExecute(function_description="Waiting for AVD(s) to boot up", 108 result_evaluator=utils.BootEvaluator) 147 with utils.TempDir() as tempdir: 159 utils.MakeTarFile(src_dict, output_file) 245 forwarded_ports = utils.AutoConnect( 248 target_vnc_port=utils.AVD_PORT_DICT[avd_type].vnc_port, 249 target_adb_port=utils.AVD_PORT_DICT[avd_type].adb_port, 258 utils.EstablishWebRTCSshTunnel(
|
/tools/acloud/setup/ |
D | host_setup_runner.py | 32 from acloud.internal.lib import utils 67 if not utils.IsSupportedPlatform(): 85 if not utils.GetUserAnswerYes("\nStart to install package(s):\n%s" 131 if not utils.IsSupportedPlatform(): 147 if not utils.GetUserAnswerYes("\nStart to install cuttlefish-common :\n%s" 176 if not utils.IsSupportedPlatform(): 179 return not (utils.CheckUserInGroups(constants.LIST_CF_USER_GROUPS) 229 answer_client = utils.InteractWithQuestion( 231 utils.TextColors.WARNING)
|
D | gcp_setup_runner.py | 27 from acloud.internal.lib import utils 115 utils.CreateSshKeyPairIfNotExist(_DEFAULT_SSH_PRIVATE_KEY, 169 return utils.CheckOutput([self.gcloud_command_path] + cmd, 183 return utils.CheckOutput([self.gsutil_command_path] + cmd, 223 msg_color = (utils.TextColors.FAIL if self._required else 224 utils.TextColors.WARNING) 225 utils.PrintColorString( 343 return utils.GetUserAnswerYes(user_question)
|
/tools/test/connectivity/acts/framework/acts/controllers/sniffer_lib/local/ |
D | local_base.py | 30 from acts import utils 57 utils.exe_cmd("ifconfig", self._interface, "down") 58 utils.exe_cmd("iwconfig", self._interface, "mode", "monitor") 59 utils.exe_cmd("ifconfig", self._interface, "up") 90 utils.exe_cmd("iwconfig", self._interface, "channel", 131 self._process = utils.start_standing_subprocess(cmd) 140 utils.stop_standing_subprocess(self._process, kill_signal=signal.SIGINT) 150 utils.wait_for_standing_subprocess(self._process, timeout)
|