Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Removed some more imports/warnings useless after recent removals.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17850 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 6d9227bb0fd3e85db604ca36dba2cfb1d8ef877d 1 parent d2e273e
@claudep claudep authored
View
9 django/contrib/formtools/tests/__init__.py
@@ -7,7 +7,6 @@
from django.contrib.formtools import preview, utils
from django.contrib.formtools.wizard import FormWizard
from django.test import TestCase
-from django.test.utils import get_warnings_state, restore_warnings_state
from django.utils import unittest
from django.contrib.formtools.tests.wizard import *
@@ -47,20 +46,12 @@ class PreviewTests(FormToolsTestCase):
def setUp(self):
super(PreviewTests, self).setUp()
- self.save_warnings_state()
- warnings.filterwarnings('ignore', category=DeprecationWarning,
- module='django.contrib.formtools.utils')
-
# Create a FormPreview instance to share between tests
self.preview = preview.FormPreview(TestForm)
input_template = '<input type="hidden" name="%s" value="%s" />'
self.input = input_template % (self.preview.unused_name('stage'), "%d")
self.test_data = {'field1':u'foo', 'field1_':u'asdf'}
- def tearDown(self):
- super(PreviewTests, self).tearDown()
- self.restore_warnings_state()
-
def test_unused_name(self):
"""
Verifies name mangling to get uniue field name.
View
3  tests/regressiontests/test_runner/tests.py
@@ -3,9 +3,7 @@
"""
from __future__ import absolute_import
-import StringIO
from optparse import make_option
-import warnings
from django.core.exceptions import ImproperlyConfigured
from django.core.management import call_command
@@ -13,7 +11,6 @@
from django.test import simple
from django.test.simple import DjangoTestSuiteRunner, get_tests
from django.test.testcases import connections_support_transactions
-from django.test.utils import get_warnings_state, restore_warnings_state
from django.utils import unittest
from django.utils.importlib import import_module
Please sign in to comment.
Something went wrong with that request. Please try again.