diff --git a/tests/test_bound_fields.py b/tests/test_bound_fields.py index cd0277123..bfc54b233 100644 --- a/tests/test_bound_fields.py +++ b/tests/test_bound_fields.py @@ -39,7 +39,7 @@ class TestSimpleBoundField: serializer.is_valid() assert serializer['text'].value == 'x' * 1000 - assert serializer['text'].errors == ['Ensure this value has at most 100 characters (it has 1000).'] + assert serializer['text'].errors == ['Ensure this field has no more than 100 characters.'] assert serializer['text'].name == 'text' assert serializer['amount'].value is 123 assert serializer['amount'].errors is None diff --git a/tests/test_generics.py b/tests/test_generics.py index a061c27df..000adffa7 100644 --- a/tests/test_generics.py +++ b/tests/test_generics.py @@ -154,7 +154,7 @@ class TestRootView(TestCase): data = {'text': 'foobar' * 100} request = factory.post('/', data, HTTP_ACCEPT='text/html') response = self.view(request).render() - expected_error = 'Ensure this value has at most 100 characters (it has 600).' + expected_error = 'Ensure this field has no more than 100 characters.' self.assertIn(expected_error, response.rendered_content.decode('utf-8')) @@ -301,7 +301,7 @@ class TestInstanceView(TestCase): data = {'text': 'foobar' * 100} request = factory.put('/', data, HTTP_ACCEPT='text/html') response = self.view(request, pk=1).render() - expected_error = 'Ensure this value has at most 100 characters (it has 600).' + expected_error = 'Ensure this field has no more than 100 characters.' self.assertIn(expected_error, response.rendered_content.decode('utf-8'))