Commit fe594161 authored by Doug Turner's avatar Doug Turner Committed by Commit Bot

Exit early from nvda_chrome_tests.py if nvda.exe is running.

Bug: 742592
Change-Id: I92fe2330345f60d599e6fd7c77d5c74c20237268
Reviewed-on: https://chromium-review.googlesource.com/599569
Commit-Queue: Doug Turner <dougt@chromium.org>
Reviewed-by: default avatarAlice Boxhall <aboxhall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#491797}
parent c2849f19
...@@ -57,6 +57,13 @@ class NvdaChromeTest(unittest.TestCase): ...@@ -57,6 +57,13 @@ class NvdaChromeTest(unittest.TestCase):
print('nvda: %s' % NVDA_PATH) print('nvda: %s' % NVDA_PATH)
print('nvda_proctest: %s' % NVDA_PROCTEST_PATH) print('nvda_proctest: %s' % NVDA_PROCTEST_PATH)
tasklist = subprocess.Popen("tasklist", shell=True, stdout=subprocess.PIPE)
tasklist_output = tasklist.communicate()[0].decode('utf8').split('\r\n')
for task in tasklist_output:
if (task.split(' ', 1)[0] == "nvda.exe"):
print("nvda.exe is running! Please kill it before running these tests")
sys.exit()
print() print()
print('Clearing user data directory and log file from previous runs') print('Clearing user data directory and log file from previous runs')
if os.access(NVDA_LOGPATH, os.F_OK): if os.access(NVDA_LOGPATH, os.F_OK):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment