Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(107)

Unified Diff: client/tests/kvm/tests/whql_client_install.py

Issue 4823005: Merge remote branch 'cros/upstream' into tempbranch (Closed) Base URL: http://git.chromium.org/git/autotest.git@master
Patch Set: patch Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « client/tests/kvm/tests/vlan_tag.py ('k') | client/tests/kvm/tests_base.cfg.sample » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/tests/kvm/tests/whql_client_install.py
diff --git a/client/tests/kvm/tests/whql_client_install.py b/client/tests/kvm/tests/whql_client_install.py
index d866df7ed88ea68adb1a6bda3e8a1d64ad9a3dd8..84b91bc282431188590d8a08df0dfb09bd682e19 100644
--- a/client/tests/kvm/tests/whql_client_install.py
+++ b/client/tests/kvm/tests/whql_client_install.py
@@ -60,7 +60,11 @@ def run_whql_client_install(test, params, env):
server_workgroup = server_workgroup.splitlines()[-1]
regkey = r"HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters"
cmd = "reg query %s /v Domain" % regkey
- server_dns_suffix = server_session.get_command_output(cmd).split()[-1]
+ o = server_session.get_command_output(cmd).strip().splitlines()[-1]
+ try:
+ server_dns_suffix = o.split(None, 2)[2]
+ except IndexError:
+ server_dns_suffix = ""
# Delete the client machine from the server's data store (if it's there)
server_session.get_command_output("cd %s" % server_studio_path)
@@ -86,7 +90,7 @@ def run_whql_client_install(test, params, env):
# Set the client machine's DNS suffix
logging.info("Setting DNS suffix to '%s'" % server_dns_suffix)
- cmd = "reg add %s /v Domain /d %s /f" % (regkey, server_dns_suffix)
+ cmd = 'reg add %s /v Domain /d "%s" /f' % (regkey, server_dns_suffix)
if session.get_command_status(cmd, timeout=300) != 0:
raise error.TestError("Could not set the client's DNS suffix")
« no previous file with comments | « client/tests/kvm/tests/vlan_tag.py ('k') | client/tests/kvm/tests_base.cfg.sample » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698