OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import logging | 6 import logging |
7 import os | 7 import os |
8 import subprocess | 8 import subprocess |
9 import sys | 9 import sys |
10 import time | 10 import time |
11 | 11 |
12 import pyauto_functional | 12 import pyauto_functional |
13 import pyauto | 13 import pyauto |
14 | 14 |
15 sys.path.append('/usr/local') # To make autotest libs importable. | 15 sys.path.append('/usr/local') # To make autotest libs importable. |
16 from autotest.cros import cros_ui | 16 from autotest.cros import cros_ui |
17 from autotest.cros import cryptohome | 17 from autotest.cros import cryptohome |
18 | 18 |
19 | 19 |
20 class AccessibilityTest(pyauto.PyUITest): | 20 class AccessibilityTest(pyauto.PyUITest): |
21 """Tests for Accessibility. | 21 """Tests for Accessibility. |
22 | 22 |
23 Test various chromeos functionalities while Accessibility is turned on. | 23 Test various chromeos functionalities while Accessibility is turned on. |
24 """ | 24 """ |
25 find_test_data_dir = 'find_in_page' | 25 find_test_data_dir = 'find_in_page' |
26 | 26 |
| 27 def ShouldAutoLogin(self): |
| 28 return False |
| 29 |
27 def setUp(self): | 30 def setUp(self): |
28 # We want a clean session_manager instance for every run, | 31 # We want a clean session_manager instance for every run, |
29 # so restart ui now. | 32 # so restart ui now. |
30 cros_ui.stop(allow_fail=True) | 33 cros_ui.stop(allow_fail=True) |
31 cryptohome.remove_all_vaults() | 34 cryptohome.remove_all_vaults() |
32 cros_ui.start(wait_for_login_prompt=False) | 35 cros_ui.start(wait_for_login_prompt=False) |
33 pyauto.PyUITest.setUp(self) | 36 pyauto.PyUITest.setUp(self) |
34 | 37 |
35 def tearDown(self): | 38 def tearDown(self): |
36 self._DisableSpokenFeedback() | 39 self._DisableSpokenFeedback() |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 # Verify that opened tab page behaves normally when Spoken Feedback is | 106 # Verify that opened tab page behaves normally when Spoken Feedback is |
104 # enabled. crosbug.com/26731 | 107 # enabled. crosbug.com/26731 |
105 url = self.GetFileURLForDataPath(self.find_test_data_dir, 'largepage.html') | 108 url = self.GetFileURLForDataPath(self.find_test_data_dir, 'largepage.html') |
106 self.NavigateToURL(url) | 109 self.NavigateToURL(url) |
107 self.assertEqual(373, self.FindInPage('daughter of Prince')['match_count'], | 110 self.assertEqual(373, self.FindInPage('daughter of Prince')['match_count'], |
108 msg='Failed to load the page or find the page contents.') | 111 msg='Failed to load the page or find the page contents.') |
109 | 112 |
110 | 113 |
111 if __name__ == '__main__': | 114 if __name__ == '__main__': |
112 pyauto_functional.Main() | 115 pyauto_functional.Main() |
OLD | NEW |