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

Side by Side Diff: chrome/test/pyautolib/pyauto.py

Issue 3083028: PyAuto test for renderer crash reporting (Closed)
Patch Set: jrg Created 10 years, 4 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
« no previous file with comments | « chrome/test/functional/crash_reporter.py ('k') | chrome/test/pyautolib/pyauto_utils.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 #!/usr/bin/python 1 #!/usr/bin/python
2 2
3 # Copyright (c) 2010 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2010 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """PyAuto: Python Interface to Chromium's Automation Proxy. 7 """PyAuto: Python Interface to Chromium's Automation Proxy.
8 8
9 PyAuto uses swig to expose Automation Proxy interfaces to Python. 9 PyAuto uses swig to expose Automation Proxy interfaces to Python.
10 For complete documentation on the functionality available, 10 For complete documentation on the functionality available,
(...skipping 1376 matching lines...) Expand 10 before | Expand all | Expand 10 after
1387 '', '--list-missing-tests', action='store_true', default=False, 1387 '', '--list-missing-tests', action='store_true', default=False,
1388 help='Print a list of tests not included in PYAUTO_TESTS, and exit') 1388 help='Print a list of tests not included in PYAUTO_TESTS, and exit')
1389 parser.add_option( 1389 parser.add_option(
1390 '', '--repeat', type='int', default=1, 1390 '', '--repeat', type='int', default=1,
1391 help='Number of times to repeat the tests. Useful to determine ' 1391 help='Number of times to repeat the tests. Useful to determine '
1392 'flakiness. Defaults to 1.') 1392 'flakiness. Defaults to 1.')
1393 1393
1394 self._options, self._args = parser.parse_args() 1394 self._options, self._args = parser.parse_args()
1395 1395
1396 # Setup logging - start with defaults 1396 # Setup logging - start with defaults
1397 level = logging.WARNING 1397 level = logging.INFO
1398 format = None 1398 format = None
1399 1399
1400 if self._options.verbose: 1400 if self._options.verbose:
1401 level=logging.DEBUG 1401 level=logging.DEBUG
1402 format='%(asctime)s %(levelname)-8s %(message)s' 1402 format='%(asctime)s %(levelname)-8s %(message)s'
1403 1403
1404 logging.basicConfig(level=level, format=format, 1404 logging.basicConfig(level=level, format=format,
1405 filename=self._options.log_file) 1405 filename=self._options.log_file)
1406 1406
1407 if self._options.list_missing_tests: 1407 if self._options.list_missing_tests:
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
1576 if self._options.verbose: 1576 if self._options.verbose:
1577 verbosity = 2 1577 verbosity = 2
1578 result = unittest.TextTestRunner(verbosity=verbosity).run(pyauto_suite) 1578 result = unittest.TextTestRunner(verbosity=verbosity).run(pyauto_suite)
1579 del loaded_tests # Need to destroy test cases before the suite 1579 del loaded_tests # Need to destroy test cases before the suite
1580 del pyauto_suite 1580 del pyauto_suite
1581 sys.exit(not result.wasSuccessful()) 1581 sys.exit(not result.wasSuccessful())
1582 1582
1583 1583
1584 if __name__ == '__main__': 1584 if __name__ == '__main__':
1585 Main() 1585 Main()
OLDNEW
« no previous file with comments | « chrome/test/functional/crash_reporter.py ('k') | chrome/test/pyautolib/pyauto_utils.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698