mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-14 13:46:59 +03:00
add test
This commit is contained in:
parent
04adfb9c94
commit
836328594b
|
@ -63,6 +63,7 @@ class RegularFieldsModel(models.Model):
|
||||||
slug_field = models.SlugField(max_length=100)
|
slug_field = models.SlugField(max_length=100)
|
||||||
small_integer_field = models.SmallIntegerField()
|
small_integer_field = models.SmallIntegerField()
|
||||||
text_field = models.TextField(max_length=100)
|
text_field = models.TextField(max_length=100)
|
||||||
|
file_field = models.FileField(max_length=100)
|
||||||
time_field = models.TimeField()
|
time_field = models.TimeField()
|
||||||
url_field = models.URLField(max_length=100)
|
url_field = models.URLField(max_length=100)
|
||||||
custom_field = CustomField()
|
custom_field = CustomField()
|
||||||
|
@ -181,6 +182,7 @@ class TestRegularFieldMappings(TestCase):
|
||||||
slug_field = SlugField(max_length=100)
|
slug_field = SlugField(max_length=100)
|
||||||
small_integer_field = IntegerField()
|
small_integer_field = IntegerField()
|
||||||
text_field = CharField(max_length=100, style={'base_template': 'textarea.html'})
|
text_field = CharField(max_length=100, style={'base_template': 'textarea.html'})
|
||||||
|
file_field = FileField(max_length=100)
|
||||||
time_field = TimeField()
|
time_field = TimeField()
|
||||||
url_field = URLField(max_length=100)
|
url_field = URLField(max_length=100)
|
||||||
custom_field = ModelField(model_field=<tests.test_model_serializer.CustomField: custom_field>)
|
custom_field = ModelField(model_field=<tests.test_model_serializer.CustomField: custom_field>)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user