diff options
| author | Tim Graham <timograham@gmail.com> | 2014-10-17 10:31:49 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-10-17 10:31:49 -0400 |
| commit | 7ae03204ac207bee78d668952744da853a3a732b (patch) | |
| tree | 7c102ad771b72a4fbb7958f515e2c51c9be87b9f /tests | |
| parent | 6ce6c77e03fea68ef1bdadd45f15e403f5b71057 (diff) | |
Fixed #23469 -- Removed test runner compatibility check which often yielded false positives.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/check_framework/tests.py | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/tests/check_framework/tests.py b/tests/check_framework/tests.py index d603cf926e..4d29429313 100644 --- a/tests/check_framework/tests.py +++ b/tests/check_framework/tests.py @@ -86,47 +86,6 @@ class MessageTests(TestCase): class Django_1_6_0_CompatibilityChecks(TestCase): - @override_settings(TEST_RUNNER='django.test.runner.DiscoverRunner') - def test_test_runner_new_default(self): - errors = check_1_6_compatibility() - self.assertEqual(errors, []) - - @override_settings(TEST_RUNNER='myapp.test.CustomRunner') - def test_test_runner_overriden(self): - errors = check_1_6_compatibility() - self.assertEqual(errors, []) - - def test_test_runner_not_set_explicitly(self): - # If TEST_RUNNER was set explicitly, temporarily pretend it wasn't - test_runner_overridden = False - if 'TEST_RUNNER' in settings._wrapped._explicit_settings: - test_runner_overridden = True - settings._wrapped._explicit_settings.remove('TEST_RUNNER') - # We remove some settings to make this look like a project generated under Django 1.5. - settings._wrapped._explicit_settings.add('MANAGERS') - settings._wrapped._explicit_settings.add('ADMINS') - try: - errors = check_1_6_compatibility() - expected = [ - checks.Warning( - "Some project unittests may not execute as expected.", - hint=("Django 1.6 introduced a new default test runner. It looks like " - "this project was generated using Django 1.5 or earlier. You should " - "ensure your tests are all running & behaving as expected. See " - "https://docs.djangoproject.com/en/dev/releases/1.6/#new-test-runner " - "for more information."), - obj=None, - id='1_6.W001', - ) - ] - self.assertEqual(errors, expected) - finally: - # Restore settings value - if test_runner_overridden: - settings._wrapped._explicit_settings.add('TEST_RUNNER') - settings._wrapped._explicit_settings.remove('MANAGERS') - settings._wrapped._explicit_settings.remove('ADMINS') - @override_settings(TEST_RUNNER='myapp.test.CustomRunner') def test_boolean_field_default_value(self): # We patch the field's default value to trigger the warning |
