Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Enabled the admin selenium tests to run on Chrome.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17574 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit a65eed39425581b206f934dd6eed960af8a64f3e 1 parent 354c84d
@jphalip jphalip authored
View
5 tests/regressiontests/admin_inlines/tests.py
@@ -383,6 +383,7 @@ def test_inline_change_fk_all_perms(self):
self.assertContains(response, '<input type="hidden" name="inner2_set-0-id" value="%i"' % self.inner2_id)
self.assertContains(response, 'id="id_inner2_set-0-DELETE"')
+
class SeleniumFirefoxTests(AdminSeleniumWebDriverTestCase):
webdriver_class = 'selenium.webdriver.firefox.webdriver.WebDriver'
fixtures = ['admin-views-users.xml']
@@ -487,3 +488,7 @@ def test_delete_inlines(self):
'form#profilecollection_form tr.dynamic-profile_set#profile_set-1')), 1)
self.failUnlessEqual(len(self.selenium.find_elements_by_css_selector(
'form#profilecollection_form tr.dynamic-profile_set#profile_set-2')), 1)
+
+
+class SeleniumChromeTests(SeleniumFirefoxTests):
+ webdriver_class = 'selenium.webdriver.chrome.webdriver.WebDriver'
View
8 tests/regressiontests/admin_views/tests.py
@@ -2894,7 +2894,8 @@ def test_prepopulated_maxlength_localized(self):
self.assertContains(response, "maxLength: 1000") # instead of 1,000
-class SeleniumPrePopulatedTests(AdminSeleniumWebDriverTestCase):
+class SeleniumPrePopulatedFirefoxTests(AdminSeleniumWebDriverTestCase):
+ webdriver_class = 'selenium.webdriver.firefox.webdriver.WebDriver'
urls = "regressiontests.admin_views.urls"
fixtures = ['admin-views-users.xml']
@@ -2997,6 +2998,11 @@ def test_basic(self):
slug2='option-one-tabular-inline-ignored-characters',
)
+
+class SeleniumPrePopulatedChromeTests(SeleniumPrePopulatedFirefoxTests):
+ webdriver_class = 'selenium.webdriver.chrome.webdriver.WebDriver'
+
+
class ReadonlyTest(TestCase):
urls = "regressiontests.admin_views.urls"
fixtures = ['admin-views-users.xml']
View
7 tests/regressiontests/admin_widgets/tests.py
@@ -438,7 +438,7 @@ def test_show_hide_date_time_picker_widgets(self):
self.assertEqual(
self.get_css_value('#calendarbox0', 'display'), 'block')
# Press the ESC key
- self.selenium.find_element_by_tag_name('html').send_keys([Keys.ESCAPE])
+ self.selenium.find_element_by_tag_name('body').send_keys([Keys.ESCAPE])
# Check that the date picker is hidden again
self.assertEqual(
self.get_css_value('#calendarbox0', 'display'), 'none')
@@ -453,7 +453,10 @@ def test_show_hide_date_time_picker_widgets(self):
self.assertEqual(
self.get_css_value('#clockbox0', 'display'), 'block')
# Press the ESC key
- self.selenium.find_element_by_tag_name('html').send_keys([Keys.ESCAPE])
+ self.selenium.find_element_by_tag_name('body').send_keys([Keys.ESCAPE])
# Check that the time picker is hidden again
self.assertEqual(
self.get_css_value('#clockbox0', 'display'), 'none')
+
+class SeleniumChromeTests(SeleniumFirefoxTests):
+ webdriver_class = 'selenium.webdriver.chrome.webdriver.WebDriver'
Please sign in to comment.
Something went wrong with that request. Please try again.