@@ -20,6 +20,7 @@ def is_authenticated(self):
20
20
21
21
class ExamplePagination (pagination .PageNumberPagination ):
22
22
page_size = 100
23
+ page_size_query_param = 'page_size'
23
24
24
25
25
26
class EmptySerializer (serializers .Serializer ):
@@ -64,7 +65,6 @@ def get_serializer(self, *args, **kwargs):
64
65
assert self .action
65
66
return super (ExampleViewSet , self ).get_serializer (* args , ** kwargs )
66
67
67
-
68
68
if coreapi :
69
69
schema_view = get_schema_view (title = 'Example API' )
70
70
else :
@@ -96,6 +96,7 @@ def test_anonymous_request(self):
96
96
action = 'get' ,
97
97
fields = [
98
98
coreapi .Field ('page' , required = False , location = 'query' ),
99
+ coreapi .Field ('page_size' , required = False , location = 'query' ),
99
100
coreapi .Field ('ordering' , required = False , location = 'query' )
100
101
]
101
102
),
@@ -136,6 +137,7 @@ def test_authenticated_request(self):
136
137
action = 'get' ,
137
138
fields = [
138
139
coreapi .Field ('page' , required = False , location = 'query' ),
140
+ coreapi .Field ('page_size' , required = False , location = 'query' ),
139
141
coreapi .Field ('ordering' , required = False , location = 'query' )
140
142
]
141
143
),
0 commit comments