Skip to content

Commit

Permalink
fix tests under 3.5
Browse files Browse the repository at this point in the history
  • Loading branch information
shalupov committed Aug 3, 2016
1 parent 8bdc557 commit 6112599
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 2 additions & 0 deletions tests/integration-tests/django_integration_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ def venv(request):

if request.param != "django==1.6" and sys.version_info < (2, 7):
pytest.skip("Django 1.7+ requires Python 2.7+")
if (request.param == "django==1.6" or request.param == "django==1.7") and sys.version_info >= (3, 5):
pytest.skip("Django supports Python 3.5+ since 1.8.6")
if request.param == "django":
if sys.version_info[0] == 2 and sys.version_info < (2, 7):
pytest.skip("Django 1.9+ requires Python 2.7+")
Expand Down
7 changes: 6 additions & 1 deletion tests/integration-tests/unittest_integration_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,12 @@ def test_discovery(venv):
@pytest.mark.skipif("sys.version_info < (2, 7)", reason="unittest discovery requires Python 2.7+")
def test_discovery_errors(venv):
output = run_directly(venv, 'discovery_errors.py')
test_name = 'unittest.loader.ModuleImportFailure.testsimple'

if sys.version_info >= (3, 5):
test_name = "unittest.loader._FailedTest.testsimple"
else:
test_name = 'unittest.loader.ModuleImportFailure.testsimple'

ms = assert_service_messages(
output,
[
Expand Down

0 comments on commit 6112599

Please sign in to comment.