File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -177,21 +177,25 @@ def mimetype(request):
177
177
return request .param
178
178
179
179
180
+ def _make_accept_header (mimetype ):
181
+ return [('Accept' , mimetype )]
182
+
183
+
180
184
@pytest .fixture
181
185
def accept_mimetype (mimetype ):
182
- return [( 'Accept' , mimetype )]
186
+ return _make_accept_header ( mimetype )
183
187
184
188
185
189
@pytest .fixture
186
190
def accept_json (request ):
187
- return accept_mimetype ('application/json' )
191
+ return _make_accept_header ('application/json' )
188
192
189
193
190
194
@pytest .fixture
191
195
def accept_jsonp ():
192
- return accept_mimetype ('application/json-p' )
196
+ return _make_accept_header ('application/json-p' )
193
197
194
198
195
199
@pytest .fixture (params = ['*' , '*/*' ])
196
200
def accept_any (request ):
197
- return accept_mimetype (request .param )
201
+ return _make_accept_header (request .param )
You can’t perform that action at this time.
0 commit comments