mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-07-17 19:52:25 +03:00
Add test
This commit is contained in:
parent
3d3a6a8ea9
commit
9ea67bd745
|
@ -9,6 +9,7 @@ from rest_framework.serializers import ModelSerializer
|
|||
from rest_framework.utils import json
|
||||
from rest_framework.utils.breadcrumbs import get_breadcrumbs
|
||||
from rest_framework.utils.formatting import lazy_format
|
||||
from rest_framework.utils.model_meta import FieldInfo, RelationInfo
|
||||
from rest_framework.utils.urls import remove_query_param, replace_query_param
|
||||
from rest_framework.views import APIView
|
||||
from rest_framework.viewsets import ModelViewSet
|
||||
|
@ -267,3 +268,9 @@ class LazyFormatTests(TestCase):
|
|||
assert message.format.call_count == 1
|
||||
str(formatted)
|
||||
assert message.format.call_count == 1
|
||||
|
||||
|
||||
class ModelMetaNamedTupleNames(TestCase):
|
||||
def test_named_tuple_names(self):
|
||||
assert FieldInfo.__name__ == 'FieldInfo'
|
||||
assert RelationInfo.__name__ == 'RelationInfo'
|
||||
|
|
Loading…
Reference in New Issue
Block a user