diff --git a/django/middleware/locale.py b/django/middleware/locale.py
index cb0bf3f..bcdead5 100644
--- a/django/middleware/locale.py
+++ b/django/middleware/locale.py
@@ -38,7 +38,7 @@ class LocaleMiddleware(object):
     def process_response(self, request, response):
         language = translation.get_language()
         language_from_path = translation.get_language_from_path(
-                request.path_info, supported=self._supported_languages
+            request.path_info, supported=self._supported_languages
         )
         if (response.status_code == 404 and not language_from_path
                 and self.is_language_prefix_patterns_used()):
diff --git a/tests/mail/tests.py b/tests/mail/tests.py
index ec99afb..f169457 100644
--- a/tests/mail/tests.py
+++ b/tests/mail/tests.py
@@ -324,9 +324,9 @@ class MailTests(HeadersCheckMixin, SimpleTestCase):
 
         connection = mail.get_connection('mail.custombackend.EmailBackend')
         send_mass_mail([
-                ('Subject1', 'Content1', 'from1@example.com', ['to1@example.com']),
-                ('Subject2', 'Content2', 'from2@example.com', ['to2@example.com']),
-            ], connection=connection)
+            ('Subject1', 'Content1', 'from1@example.com', ['to1@example.com']),
+            ('Subject2', 'Content2', 'from2@example.com', ['to2@example.com']),
+        ], connection=connection)
         self.assertEqual(mail.outbox, [])
         self.assertEqual(len(connection.test_outbox), 2)
         self.assertEqual(connection.test_outbox[0].subject, 'Subject1')
diff --git a/tests/model_formsets_regress/tests.py b/tests/model_formsets_regress/tests.py
index 6715b5b..6669e53 100644
--- a/tests/model_formsets_regress/tests.py
+++ b/tests/model_formsets_regress/tests.py
@@ -369,25 +369,25 @@ class FormfieldShouldDeleteFormTests(TestCase):
     DeleteFormset = modelformset_factory(User, form=CustomDeleteUserForm, formset=BaseCustomDeleteModelFormSet)
 
     data = {
-            'form-TOTAL_FORMS': '4',
-            'form-INITIAL_FORMS': '0',
-            'form-MAX_NUM_FORMS': '4',
-            'form-0-username': 'John',
-            'form-0-serial': '1',
-            'form-1-username': 'Paul',
-            'form-1-serial': '2',
-            'form-2-username': 'George',
-            'form-2-serial': '3',
-            'form-3-username': 'Ringo',
-            'form-3-serial': '5',
-            }
+        'form-TOTAL_FORMS': '4',
+        'form-INITIAL_FORMS': '0',
+        'form-MAX_NUM_FORMS': '4',
+        'form-0-username': 'John',
+        'form-0-serial': '1',
+        'form-1-username': 'Paul',
+        'form-1-serial': '2',
+        'form-2-username': 'George',
+        'form-2-serial': '3',
+        'form-3-username': 'Ringo',
+        'form-3-serial': '5',
+    }
 
     delete_all_ids = {
-            'form-0-DELETE': '1',
-            'form-1-DELETE': '1',
-            'form-2-DELETE': '1',
-            'form-3-DELETE': '1',
-            }
+        'form-0-DELETE': '1',
+        'form-1-DELETE': '1',
+        'form-2-DELETE': '1',
+        'form-3-DELETE': '1',
+    }
 
     def test_init_database(self):
         """ Add test data to database via formset """
diff --git a/tests/reverse_single_related/tests.py b/tests/reverse_single_related/tests.py
index 472a302..5e5704a 100644
--- a/tests/reverse_single_related/tests.py
+++ b/tests/reverse_single_related/tests.py
@@ -18,10 +18,7 @@ class ReverseSingleRelatedTests(TestCase):
         private_item = Item.objects.create(source=private_source)
 
         # Only one source is available via all() due to the custom default manager.
-        self.assertQuerysetEqual(
-                Source.objects.all(),
-                ["<Source: Source object>"]
-        )
+        self.assertQuerysetEqual(Source.objects.all(), ["<Source: Source object>"])
 
         self.assertEqual(public_item.source, public_source)
 
diff --git a/tests/serializers_regress/tests.py b/tests/serializers_regress/tests.py
index a35d785..7e9dd46 100644
--- a/tests/serializers_regress/tests.py
+++ b/tests/serializers_regress/tests.py
@@ -557,9 +557,9 @@ def naturalKeyTest(format, self):
 
 
 for format in [
-            f for f in serializers.get_serializer_formats()
-            if not isinstance(serializers.get_serializer(f), serializers.BadSerializer)
-        ]:
+    f for f in serializers.get_serializer_formats()
+    if not isinstance(serializers.get_serializer(f), serializers.BadSerializer)
+]:
     setattr(SerializerTests, 'test_' + format + '_serializer', curry(serializerTest, format))
     setattr(SerializerTests, 'test_' + format + '_natural_key_serializer', curry(naturalKeySerializerTest, format))
     setattr(SerializerTests, 'test_' + format + '_serializer_fields', curry(fieldsTest, format))
diff --git a/tests/transactions/tests.py b/tests/transactions/tests.py
index a66ffe4..8c0c535 100644
--- a/tests/transactions/tests.py
+++ b/tests/transactions/tests.py
@@ -203,7 +203,7 @@ class AtomicTests(TransactionTestCase):
             with self.assertRaises(DatabaseError):
                 with transaction.atomic(savepoint=False):
                     connection.cursor().execute(
-                            "SELECT no_such_col FROM transactions_reporter")
+                        "SELECT no_such_col FROM transactions_reporter")
             # prevent atomic from rolling back since we're recovering manually
             self.assertTrue(transaction.get_rollback())
             transaction.set_rollback(False)
