summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorAlex Gaynor <alex.gaynor@gmail.com>2014-05-28 17:39:14 -0700
committerAlex Gaynor <alex.gaynor@gmail.com>2014-05-28 17:39:14 -0700
commit1dcc603efff8229838f27019668d864a0bcbfa59 (patch)
tree8c67764f440faeb095143498383ca57ecd4f09be /tests
parente79725cdf90e3271626ed66f70b63640d3fcc521 (diff)
Fixed several typos in Django
Diffstat (limited to 'tests')
-rw-r--r--tests/admin_views/admin.py2
-rw-r--r--tests/forms_tests/tests/test_formsets.py2
-rw-r--r--tests/mail/custombackend.py2
-rw-r--r--tests/model_formsets/tests.py2
-rw-r--r--tests/model_formsets_regress/models.py2
-rw-r--r--tests/model_inheritance/tests.py2
-rw-r--r--tests/model_inheritance_regress/tests.py2
-rw-r--r--tests/model_package/tests.py6
-rw-r--r--tests/multiple_database/tests.py2
-rw-r--r--tests/queries/tests.py2
-rw-r--r--tests/syndication_tests/tests.py2
-rw-r--r--tests/test_client/tests.py2
-rw-r--r--tests/urlpatterns_reverse/tests.py4
13 files changed, 16 insertions, 16 deletions
diff --git a/tests/admin_views/admin.py b/tests/admin_views/admin.py
index a5b3df3b9e..db186f6027 100644
--- a/tests/admin_views/admin.py
+++ b/tests/admin_views/admin.py
@@ -216,7 +216,7 @@ class SubscriberAdmin(admin.ModelAdmin):
def mail_admin(self, request, selected):
EmailMessage(
'Greetings from a ModelAdmin action',
- 'This is the test email from a admin action',
+ 'This is the test email from an admin action',
'from@example.com',
['to@example.com']
).send()
diff --git a/tests/forms_tests/tests/test_formsets.py b/tests/forms_tests/tests/test_formsets.py
index 6b82f57343..94e27044ff 100644
--- a/tests/forms_tests/tests/test_formsets.py
+++ b/tests/forms_tests/tests/test_formsets.py
@@ -461,7 +461,7 @@ class FormsFormsetTestCase(TestCase):
def test_formsets_with_ordering(self):
# FormSets with ordering ######################################################
# We can also add ordering ability to a FormSet with an argument to
- # formset_factory. This will add a integer field to each form instance. When
+ # formset_factory. This will add an integer field to each form instance. When
# form validation succeeds, [form.cleaned_data for form in formset.forms] will have the data in the correct
# order specified by the ordering fields. If a number is duplicated in the set
# of ordering fields, for instance form 0 and form 3 are both marked as 1, then
diff --git a/tests/mail/custombackend.py b/tests/mail/custombackend.py
index 6b0e15ad0a..ac631a6e1b 100644
--- a/tests/mail/custombackend.py
+++ b/tests/mail/custombackend.py
@@ -10,6 +10,6 @@ class EmailBackend(BaseEmailBackend):
self.test_outbox = []
def send_messages(self, email_messages):
- # Messages are stored in a instance variable for testing.
+ # Messages are stored in an instance variable for testing.
self.test_outbox.extend(email_messages)
return len(email_messages)
diff --git a/tests/model_formsets/tests.py b/tests/model_formsets/tests.py
index 2913f6c0ab..19c0a6d9d5 100644
--- a/tests/model_formsets/tests.py
+++ b/tests/model_formsets/tests.py
@@ -1165,7 +1165,7 @@ class ModelFormsetTest(TestCase):
def test_inlineformset_factory_with_null_fk(self):
# inlineformset_factory tests with fk having null=True. see #9462.
- # create some data that will exbit the issue
+ # create some data that will exhibit the issue
team = Team.objects.create(name="Red Vipers")
Player(name="Timmy").save()
Player(name="Bobby", team=team).save()
diff --git a/tests/model_formsets_regress/models.py b/tests/model_formsets_regress/models.py
index 58eed6a22b..77ee5a2a16 100644
--- a/tests/model_formsets_regress/models.py
+++ b/tests/model_formsets_regress/models.py
@@ -21,7 +21,7 @@ class Restaurant(Place):
class Manager(models.Model):
- retaurant = models.ForeignKey(Restaurant)
+ restaurant = models.ForeignKey(Restaurant)
name = models.CharField(max_length=50)
diff --git a/tests/model_inheritance/tests.py b/tests/model_inheritance/tests.py
index 15c94c6087..0af96b820d 100644
--- a/tests/model_inheritance/tests.py
+++ b/tests/model_inheritance/tests.py
@@ -69,7 +69,7 @@ class ModelInheritanceTests(TestCase):
# access to the fields of their ancestors.
# Create a couple of Places.
Place.objects.create(name="Master Shakes", address="666 W. Jersey")
- Place.objects.create(name="Ace Harware", address="1013 N. Ashland")
+ Place.objects.create(name="Ace Hardware", address="1013 N. Ashland")
# Test constructor for Restaurant.
r = Restaurant.objects.create(
diff --git a/tests/model_inheritance_regress/tests.py b/tests/model_inheritance_regress/tests.py
index 745a63f7e6..7e1c4b81bf 100644
--- a/tests/model_inheritance_regress/tests.py
+++ b/tests/model_inheritance_regress/tests.py
@@ -165,7 +165,7 @@ class ModelInheritanceTest(TestCase):
serves_hot_dogs=True,
serves_pizza=False)
- # This should delete both Restuarants, plus the related places, plus
+ # This should delete both Restaurants, plus the related places, plus
# the ItalianRestaurant.
Restaurant.objects.all().delete()
diff --git a/tests/model_package/tests.py b/tests/model_package/tests.py
index a352b57478..7dc1f84a35 100644
--- a/tests/model_package/tests.py
+++ b/tests/model_package/tests.py
@@ -8,7 +8,7 @@ from .models.publication import Publication
from .models.article import Article
-class Advertisment(models.Model):
+class Advertisement(models.Model):
customer = models.CharField(max_length=100)
publications = models.ManyToManyField(
"model_package.Publication", null=True, blank=True
@@ -33,10 +33,10 @@ class ModelPackageTests(TestCase):
self.assertEqual(a.sites.count(), 1)
# Regression for #12245 - Models can exist in the test package, too
- ad = Advertisment.objects.create(customer="Lawrence Journal-World")
+ ad = Advertisement.objects.create(customer="Lawrence Journal-World")
ad.publications.add(p)
- ad = Advertisment.objects.get(id=ad.pk)
+ ad = Advertisement.objects.get(id=ad.pk)
self.assertEqual(ad.publications.count(), 1)
# Regression for #12386 - field names on the autogenerated intermediate
diff --git a/tests/multiple_database/tests.py b/tests/multiple_database/tests.py
index 4802c97819..f3b540e31a 100644
--- a/tests/multiple_database/tests.py
+++ b/tests/multiple_database/tests.py
@@ -624,7 +624,7 @@ class QueryTestCase(TestCase):
new_bob_profile = UserProfile(flavor="spring surprise")
- # assigning a profile requires a explicit pk as the object isn't saved
+ # assigning a profile requires an explicit pk as the object isn't saved
charlie = User(pk=51, username='charlie', email='charlie@example.com')
charlie.set_unusable_password()
diff --git a/tests/queries/tests.py b/tests/queries/tests.py
index 48d45f70f1..751f9792b1 100644
--- a/tests/queries/tests.py
+++ b/tests/queries/tests.py
@@ -1710,7 +1710,7 @@ class NullableRelOrderingTests(TestCase):
qs = qs.order_by('others__single__name')
# The ordering by others__single__pk will add one new join (to single)
# and that join must be LEFT join. The already existing join to related
- # objects must be kept INNER. So, we have both a INNER and a LEFT join
+ # objects must be kept INNER. So, we have both an INNER and a LEFT join
# in the query.
self.assertEqual(str(qs.query).count('LEFT'), 1)
self.assertEqual(str(qs.query).count('INNER'), 1)
diff --git a/tests/syndication_tests/tests.py b/tests/syndication_tests/tests.py
index facb413c7f..fabc3e1eaa 100644
--- a/tests/syndication_tests/tests.py
+++ b/tests/syndication_tests/tests.py
@@ -386,7 +386,7 @@ class SyndicationFeedTest(FeedTestCase):
def test_item_link_error(self):
"""
- Test that a ImproperlyConfigured is raised if no link could be found
+ Test that an ImproperlyConfigured is raised if no link could be found
for the item(s).
"""
self.assertRaises(ImproperlyConfigured,
diff --git a/tests/test_client/tests.py b/tests/test_client/tests.py
index a04b14472f..b9c033fe15 100644
--- a/tests/test_client/tests.py
+++ b/tests/test_client/tests.py
@@ -405,7 +405,7 @@ class ClientTest(TestCase):
# TODO: Log in with right permissions and request the page again
def test_view_with_permissions_exception(self):
- "Request a page that is protected with @permission_required but raises a exception"
+ "Request a page that is protected with @permission_required but raises an exception"
# Get the page without logging in. Should result in 403.
response = self.client.get('/permission_protected_view_exception/')
diff --git a/tests/urlpatterns_reverse/tests.py b/tests/urlpatterns_reverse/tests.py
index ade0a7a68d..d40e410c2a 100644
--- a/tests/urlpatterns_reverse/tests.py
+++ b/tests/urlpatterns_reverse/tests.py
@@ -373,7 +373,7 @@ class ReverseShortcutTests(TestCase):
def test_reverse_by_path_nested(self):
# Views that are added to urlpatterns using include() should be
- # reversable by doted path.
+ # reversible by doted path.
self.assertEqual(reverse('urlpatterns_reverse.views.nested_view'), '/includes/nested_path/')
def test_redirect_view_object(self):
@@ -439,7 +439,7 @@ class NamespaceTests(TestCase):
self.assertEqual('/ns-included1/+%5C$*/', reverse('inc-ns1:inc-special-view'))
def test_namespace_pattern_with_variable_prefix(self):
- "When using a include with namespaces when there is a regex variable in front of it"
+ "When using an include with namespaces when there is a regex variable in front of it"
self.assertEqual('/ns-outer/42/normal/', reverse('inc-outer:inc-normal-view', kwargs={'outer': 42}))
self.assertEqual('/ns-outer/42/normal/', reverse('inc-outer:inc-normal-view', args=[42]))
self.assertEqual('/ns-outer/42/normal/37/4/', reverse('inc-outer:inc-normal-view', kwargs={'outer': 42, 'arg1': 37, 'arg2': 4}))