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

Unified Diff: tools/testing/run_selenium.py

Issue 10014004: Preliminary selenium support for Dartium (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Added more comments Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/get_drt.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/run_selenium.py
diff --git a/tools/testing/run_selenium.py b/tools/testing/run_selenium.py
index b092971bb1440a1a74a7bb7145c6cc52aa5b1812..4d5a66f929e336f248e23fd056b2c802d759f043 100755
--- a/tools/testing/run_selenium.py
+++ b/tools/testing/run_selenium.py
@@ -75,6 +75,7 @@ def run_test_in_browser(browser, html_out, timeout, mode):
"""Run the desired test in the browser using Selenium 2.0 WebDriver syntax,
and wait for the test to complete. This is the newer syntax, that currently
supports Firefox, Chrome, IE, Opera (and some mobile browsers)."""
+
if isinstance(browser, selenium.selenium):
return run_test_in_browser_selenium_rc(browser, html_out, timeout, mode)
@@ -131,6 +132,19 @@ def start_browser(browser, html_out):
# installing Chrome. Also note that the build bot runs have a different path
# from a normal user -- check the build logs.
return selenium.webdriver.Chrome()
+ elif browser == 'dartium':
+ script_dir = os.path.dirname(os.path.abspath(__file__))
+ dartium_dir = os.path.join(script_dir, '..', '..', 'client', 'tests',
+ 'dartium')
+ options = selenium.webdriver.chrome.options.Options()
+ if platform.system() == 'Windows':
+ options.binary_location = os.path.join(dartium_dir, 'chrome.exe')
+ elif platform.system() == 'Darwin':
+ options.binary_location = os.path.join(dartium_dir, 'Chromium.app',
+ 'Contents', 'MacOS', 'Chromium')
+ else:
+ options.binary_location = os.path.join(dartium_dir, 'chrome')
+ return selenium.webdriver.Chrome(chrome_options=options)
elif browser == 'ff':
profile = selenium.webdriver.firefox.firefox_profile.FirefoxProfile()
profile.set_preference('dom.max_script_run_time', 0)
« no previous file with comments | « tools/get_drt.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698