(app, client)
| 51 | |
| 52 | |
| 53 | def test_standard_context(app, client): |
| 54 | @app.route("/") |
| 55 | def index(): |
| 56 | flask.g.foo = 23 |
| 57 | flask.session["test"] = "aha" |
| 58 | return flask.render_template_string( |
| 59 | """ |
| 60 | {{ request.args.foo }} |
| 61 | {{ g.foo }} |
| 62 | {{ config.DEBUG }} |
| 63 | {{ session.test }} |
| 64 | """ |
| 65 | ) |
| 66 | |
| 67 | rv = client.get("/?foo=42") |
| 68 | assert rv.data.split() == [b"42", b"23", b"False", b"aha"] |
| 69 | |
| 70 | |
| 71 | def test_escaping(app, client): |