Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge pull request #946 from matiasb/minor-flatpage-translation-fix

Fixed #20117 -- Added missing translation override to fix flatpages test.
  • Loading branch information...
commit 151938ddb5f9537c80c1a6426f2c6ce14adc92d9 2 parents 9c4882b + 6985f0c
Simon Charette authored March 24, 2013

Showing 1 changed file with 5 additions and 4 deletions. Show diff stats Hide diff stats

  1. 9  django/contrib/flatpages/tests/forms.py
9  django/contrib/flatpages/tests/forms.py
@@ -58,11 +58,12 @@ def test_flatpage_admin_form_url_uniqueness_validation(self):
58 58
 
59 59
         f = FlatpageForm(data=data)
60 60
 
61  
-        self.assertFalse(f.is_valid())
  61
+        with translation.override('en'):
  62
+            self.assertFalse(f.is_valid())
62 63
 
63  
-        self.assertEqual(
64  
-            f.errors,
65  
-            {'__all__': ['Flatpage with url /myflatpage1/ already exists for site example.com']})
  64
+            self.assertEqual(
  65
+                f.errors,
  66
+                {'__all__': ['Flatpage with url /myflatpage1/ already exists for site example.com']})
66 67
 
67 68
     def test_flatpage_admin_form_edit(self):
68 69
         """

0 notes on commit 151938d

Please sign in to comment.
Something went wrong with that request. Please try again.