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

Unified Diff: client/virt/tests/mac_change.py

Issue 6883246: Merge autotest upstream from @5318 ~ @5336 (Closed) Base URL: ssh://gitrw.chromium.org:9222/autotest.git@master
Patch Set: patch Created 9 years, 8 months 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/virt/tests/linux_s3.py ('k') | client/virt/tests/multicast.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/virt/tests/mac_change.py
diff --git a/client/tests/kvm/tests/mac_change.py b/client/virt/tests/mac_change.py
similarity index 88%
rename from client/tests/kvm/tests/mac_change.py
rename to client/virt/tests/mac_change.py
index 3fd196f79e75288f54b652a5fcc36af87ceb0a9a..d2eaf01b462f24b1c52367eae3852e217e89fcd1 100644
--- a/client/tests/kvm/tests/mac_change.py
+++ b/client/virt/tests/mac_change.py
@@ -1,6 +1,6 @@
import logging
from autotest_lib.client.common_lib import error
-import kvm_utils, kvm_test_utils
+from autotest_lib.client.virt import virt_utils, virt_test_utils
def run_mac_change(test, params, env):
@@ -24,11 +24,11 @@ def run_mac_change(test, params, env):
old_mac = vm.get_mac_address(0)
while True:
vm.free_mac_address(0)
- new_mac = kvm_utils.generate_mac_address(vm.instance, 0)
+ new_mac = virt_utils.generate_mac_address(vm.instance, 0)
if old_mac != new_mac:
break
logging.info("The initial MAC address is %s", old_mac)
- interface = kvm_test_utils.get_linux_ifname(session_serial, old_mac)
+ interface = virt_test_utils.get_linux_ifname(session_serial, old_mac)
# Start change MAC address
logging.info("Changing MAC address to %s", new_mac)
change_cmd = ("ifconfig %s down && ifconfig %s hw ether %s && "
@@ -45,7 +45,7 @@ def run_mac_change(test, params, env):
session_serial.sendline(dhclient_cmd)
# Re-log into the guest after changing mac address
- if kvm_utils.wait_for(session.is_responsive, 120, 20, 3):
+ if virt_utils.wait_for(session.is_responsive, 120, 20, 3):
# Just warning when failed to see the session become dead,
# because there is a little chance the ip does not change.
logging.warn("The session is still responsive, settings may fail.")
« no previous file with comments | « client/virt/tests/linux_s3.py ('k') | client/virt/tests/multicast.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698