|
1 | 1 | import json |
2 | 2 |
|
3 | 3 | from fixture import BadRequest, MusicService, Unknown |
4 | | -from pytest import fixture, raises, mark |
| 4 | +from pytest import fixture, mark, raises |
5 | 5 | from six import text_type |
6 | | -from werkzeug.test import Client as TestClient |
| 6 | +from werkzeug.test import Client as WTestClient |
7 | 7 | from werkzeug.wrappers import Response |
8 | 8 |
|
9 | 9 | from nirum.deserialize import deserialize_meta |
@@ -59,7 +59,7 @@ def fx_music_wsgi(): |
59 | 59 |
|
60 | 60 | @fixture |
61 | 61 | def fx_test_client(fx_music_wsgi): |
62 | | - return TestClient(fx_music_wsgi, Response) |
| 62 | + return WTestClient(fx_music_wsgi, Response) |
63 | 63 |
|
64 | 64 |
|
65 | 65 | def test_wsgi_app_ping(fx_music_wsgi, fx_test_client): |
@@ -247,7 +247,7 @@ class ExtendedWsgiApp(WsgiApp): |
247 | 247 | def make_response(self, status_code, headers, content): |
248 | 248 | return (status_code, headers, content, None)[:arity] |
249 | 249 | wsgi_app = ExtendedWsgiApp(MusicServiceImpl()) |
250 | | - client = TestClient(wsgi_app, Response) |
| 250 | + client = WTestClient(wsgi_app, Response) |
251 | 251 | with raises(TypeError) as e: |
252 | 252 | client.post('/?method=get_music_by_artist_name', |
253 | 253 | data=json.dumps({'artist_name': u'damien rice'})) |
|
0 commit comments