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

Side by Side Diff: client/virt/tests/linux_s3.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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « client/virt/tests/kdump.py ('k') | client/virt/tests/mac_change.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 import logging, time 1 import logging, time
2 from autotest_lib.client.common_lib import error 2 from autotest_lib.client.common_lib import error
3 3
4 4
5 def run_linux_s3(test, params, env): 5 def run_linux_s3(test, params, env):
6 """ 6 """
7 Suspend a guest Linux OS to memory. 7 Suspend a guest Linux OS to memory.
8 8
9 @param test: kvm test object. 9 @param test: kvm test object.
10 @param params: Dictionary with test parameters. 10 @param params: Dictionary with test parameters.
(...skipping 21 matching lines...) Expand all
32 32
33 logging.info("Putting VM into S3") 33 logging.info("Putting VM into S3")
34 command = "chvt %s && echo mem > /sys/power/state && chvt %s" % (dst_tty, 34 command = "chvt %s && echo mem > /sys/power/state && chvt %s" % (dst_tty,
35 src_tty) 35 src_tty)
36 suspend_timeout = 120 + int(params.get("smp")) * 60 36 suspend_timeout = 120 + int(params.get("smp")) * 60
37 session.cmd(command, timeout=suspend_timeout) 37 session.cmd(command, timeout=suspend_timeout)
38 38
39 logging.info("VM resumed after S3") 39 logging.info("VM resumed after S3")
40 40
41 session.close() 41 session.close()
OLDNEW
« no previous file with comments | « client/virt/tests/kdump.py ('k') | client/virt/tests/mac_change.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698