Add Django 1.11 to test matrix
This commit is contained in:
parent
5c462c3d45
commit
8e7e2eb286
2 changed files with 19 additions and 1 deletions
|
@ -14,6 +14,7 @@ env:
|
||||||
- DJANGO_VERSION='Django>=1.8,<1.9'
|
- DJANGO_VERSION='Django>=1.8,<1.9'
|
||||||
- DJANGO_VERSION='Django>=1.9,<1.10'
|
- DJANGO_VERSION='Django>=1.9,<1.10'
|
||||||
- DJANGO_VERSION='Django>=1.10,<1.11'
|
- DJANGO_VERSION='Django>=1.10,<1.11'
|
||||||
|
- DJANGO_VERSION='Django>=1.11,<2.0'
|
||||||
- DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
- DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
||||||
matrix:
|
matrix:
|
||||||
exclude:
|
exclude:
|
||||||
|
@ -26,6 +27,10 @@ matrix:
|
||||||
- python: "2.6"
|
- python: "2.6"
|
||||||
env: DJANGO_VERSION='Django>=1.10,<1.11'
|
env: DJANGO_VERSION='Django>=1.10,<1.11'
|
||||||
- python: "2.6"
|
- python: "2.6"
|
||||||
|
env: DJANGO_VERSION='Django>=1.11,<2.0'
|
||||||
|
- python: "2.6"
|
||||||
|
env: DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
||||||
|
- python: "2.7"
|
||||||
env: DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
env: DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
||||||
- python: "3.3"
|
- python: "3.3"
|
||||||
env: DJANGO_VERSION='Django>=1.4,<1.5'
|
env: DJANGO_VERSION='Django>=1.4,<1.5'
|
||||||
|
@ -35,6 +40,8 @@ matrix:
|
||||||
env: DJANGO_VERSION='Django>=1.9,<1.10'
|
env: DJANGO_VERSION='Django>=1.9,<1.10'
|
||||||
- python: "3.3"
|
- python: "3.3"
|
||||||
env: DJANGO_VERSION='Django>=1.10,<1.11'
|
env: DJANGO_VERSION='Django>=1.10,<1.11'
|
||||||
|
- python: "3.3"
|
||||||
|
env: DJANGO_VERSION='Django>=1.11,<2.0'
|
||||||
- python: "3.3"
|
- python: "3.3"
|
||||||
env: DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
env: DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
||||||
- python: "3.4"
|
- python: "3.4"
|
||||||
|
@ -43,6 +50,8 @@ matrix:
|
||||||
env: DJANGO_VERSION='Django>=1.5,<1.6'
|
env: DJANGO_VERSION='Django>=1.5,<1.6'
|
||||||
- python: "3.4"
|
- python: "3.4"
|
||||||
env: DJANGO_VERSION='Django>=1.6,<1.7'
|
env: DJANGO_VERSION='Django>=1.6,<1.7'
|
||||||
|
- python: "3.4"
|
||||||
|
env: DJANGO_VERSION='https://github.com/django/django/archive/master.tar.gz'
|
||||||
- python: "3.5"
|
- python: "3.5"
|
||||||
env: DJANGO_VERSION='Django>=1.4,<1.5'
|
env: DJANGO_VERSION='Django>=1.4,<1.5'
|
||||||
- python: "3.5"
|
- python: "3.5"
|
||||||
|
|
|
@ -144,13 +144,22 @@ class MultiSelectTestCase(TestCase):
|
||||||
"""<li>USA - States<ul id="id_published_in_1"><li><label for="id_published_in_1_0"><input checked="checked" id="id_published_in_1_0" name="published_in" type="checkbox" value="AK" /> Alaska</label></li>\n"""
|
"""<li>USA - States<ul id="id_published_in_1"><li><label for="id_published_in_1_0"><input checked="checked" id="id_published_in_1_0" name="published_in" type="checkbox" value="AK" /> Alaska</label></li>\n"""
|
||||||
"""<li><label for="id_published_in_1_1"><input id="id_published_in_1_1" name="published_in" type="checkbox" value="AL" /> Alabama</label></li>\n"""
|
"""<li><label for="id_published_in_1_1"><input id="id_published_in_1_1" name="published_in" type="checkbox" value="AL" /> Alabama</label></li>\n"""
|
||||||
"""<li><label for="id_published_in_1_2"><input id="id_published_in_1_2" name="published_in" type="checkbox" value="AZ" /> Arizona</label></li></ul></li></ul></p>""")
|
"""<li><label for="id_published_in_1_2"><input id="id_published_in_1_2" name="published_in" type="checkbox" value="AZ" /> Arizona</label></li></ul></li></ul></p>""")
|
||||||
|
|
||||||
actual_html = form.as_p()
|
actual_html = form.as_p()
|
||||||
|
|
||||||
if VERSION < (1, 6) or VERSION >= (1, 7):
|
if (1, 11) <= VERSION < (2, 0):
|
||||||
|
# Django 1.11+ does not assign 'for' attributes on labels if they
|
||||||
|
# are group labels
|
||||||
|
expected_html = expected_html.replace('label for="id_published_in_0"', 'label')
|
||||||
|
|
||||||
|
if VERSION < (1, 6):
|
||||||
# Django 1.6 renders the Python repr() for each group (eg: tuples
|
# Django 1.6 renders the Python repr() for each group (eg: tuples
|
||||||
# with HTML entities), so we skip the test for that version
|
# with HTML entities), so we skip the test for that version
|
||||||
self.assertEqual(expected_html.replace('\n', ''), actual_html.replace('\n', ''))
|
self.assertEqual(expected_html.replace('\n', ''), actual_html.replace('\n', ''))
|
||||||
|
|
||||||
|
if VERSION >= (1, 7):
|
||||||
|
self.assertHTMLEqual(expected_html, actual_html)
|
||||||
|
|
||||||
|
|
||||||
class MultiSelectUtilsTestCase(TestCase):
|
class MultiSelectUtilsTestCase(TestCase):
|
||||||
def test_get_max_length_max_length_is_not_none(self):
|
def test_get_max_length_max_length_is_not_none(self):
|
||||||
|
|
Loading…
Reference in a new issue