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

Unified Diff: pyautolib/pyauto.py

Issue 10384104: Chrome updater test framework (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/chrome/test/
Patch Set: Created 8 years, 7 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
« pyautolib/fetch_prebuilt_pyauto.py ('K') | « pyautolib/fetch_prebuilt_pyauto.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pyautolib/pyauto.py
===================================================================
--- pyautolib/pyauto.py (revision 136323)
+++ pyautolib/pyauto.py (working copy)
@@ -49,6 +49,7 @@
import urllib
import pyauto_paths
+from py_unittest_util import GTestTextTestRunner
def _LocateBinDirs():
@@ -134,11 +135,15 @@
homepage: the home page. Defaults to "about:blank"
"""
# Fetch provided keyword args, or fill in defaults.
+ browser_path = kwargs.get('browser_path', None)
clear_profile = kwargs.get('clear_profile', True)
homepage = kwargs.get('homepage', 'about:blank')
pyautolib.PyUITestBase.__init__(self, clear_profile, homepage)
- self.Initialize(pyautolib.FilePath(self.BrowserPath()))
+ if browser_path:
+ self.Initialize(pyautolib.FilePath(browser_path))
+ else:
+ self.Initialize(pyautolib.FilePath(self.BrowserPath()))
unittest.TestCase.__init__(self, methodName)
# Give all pyauto tests easy access to pprint.PrettyPrinter functions.
@@ -5735,8 +5740,8 @@
pyauto_suite.addTests(loaded_tests)
verbosity = 1
if self._options.verbose:
- verbosity = 2
- result = PyAutoTextTestRunner(verbosity=verbosity).run(pyauto_suite)
+ verbosity = 2
+ result = GTestTextTestRunner(verbosity=verbosity).run(pyauto_suite)
del loaded_tests # Need to destroy test cases before the suite
del pyauto_suite
successful = result.wasSuccessful()
« pyautolib/fetch_prebuilt_pyauto.py ('K') | « pyautolib/fetch_prebuilt_pyauto.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698