Browse Source

failing test for streaming session

pull/2354/head
David Lord 7 years ago
parent
commit
5978a0f55f
No known key found for this signature in database
GPG Key ID: 7A1C87E3F5BC42A8
  1. 14
      tests/test_helpers.py

14
tests/test_helpers.py

@ -861,6 +861,20 @@ class TestStreaming(object):
assert rv.data == b'Hello World!'
assert called == [42]
def test_stream_keeps_session(self, app, client):
@app.route('/')
def index():
flask.session['test'] = 'flask'
@flask.stream_with_context
def gen():
yield flask.session['test']
return flask.Response(gen())
rv = client.get('/')
assert rv.data == b'flask'
class TestSafeJoin(object):
def test_safe_join(self):

Loading…
Cancel
Save