changeset a610674ec95c in trytond:6.2
details: https://hg.tryton.org/trytond?cmd=changeset&node=a610674ec95c
description:
Always use a Response wrapper when using testing client
This normalize the behavior through different versions of werkzeug.
issue11353
review385001002
(grafted from 171cdfb43730f5bcafca95149016366c794c7850)
diffstat:
trytond/tests/test_wsgi.py | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (39 lines):
diff -r 3bf2b931fc42 -r a610674ec95c trytond/tests/test_wsgi.py
--- a/trytond/tests/test_wsgi.py Fri Apr 15 21:17:05 2022 +0200
+++ b/trytond/tests/test_wsgi.py Fri Apr 22 18:32:25 2022 +0200
@@ -33,7 +33,7 @@
sentinel.request = request
raise exception
- client = Client(app)
+ client = Client(app, Response)
_ = client.get('/willfail')
spy.assert_called_once_with(app, sentinel.request, exception)
@@ -59,7 +59,7 @@
sentinel.request = request
raise exception
- client = Client(app)
+ client = Client(app, Response)
_ = client.get('/willfail')
spy1.assert_called_once_with(app, sentinel.request, exception)
@@ -83,7 +83,7 @@
sentinel.request = request
raise exception
- client = Client(app)
+ client = Client(app, Response)
_ = client.get('/willfail')
spy.assert_called_once_with(app, sentinel.request, exception)
@@ -104,7 +104,7 @@
def _route(request):
raise self.TestException('foo')
- client = Client(app)
+ client = Client(app, Response)
response = client.get('/willfail')
self.assertEqual(next(response.response), b'baz')