mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-01-24 16:24:18 +03:00
Fixed broken test for Django < 1.9
This test was incorrectly checking that there were no validators set in
older versions of Django, even though it should have been checking for
the two validators that were set up on the model field level.
The originally regression test that this fixes was added in
7d79cf35b7
when fixing an issue with the `DecimalValidator`.
This commit is contained in:
parent
87605e1e39
commit
d797389cf7
|
@ -884,7 +884,7 @@ class TestDecimalFieldMappings(TestCase):
|
|||
|
||||
serializer = TestSerializer()
|
||||
|
||||
assert len(serializer.fields['decimal_field'].validators) == 0
|
||||
assert len(serializer.fields['decimal_field'].validators) == 2
|
||||
|
||||
@pytest.mark.skipif(DecimalValidator is None,
|
||||
reason='DecimalValidator is available in Django 1.9+')
|
||||
|
|
Loading…
Reference in New Issue
Block a user