(app, client)
| 30 | |
| 31 | |
| 32 | def test_options_work(app, client): |
| 33 | @app.route("/", methods=["GET", "POST"]) |
| 34 | def index(): |
| 35 | return "Hello World" |
| 36 | |
| 37 | rv = client.open("/", method="OPTIONS") |
| 38 | assert sorted(rv.allow) == ["GET", "HEAD", "OPTIONS", "POST"] |
| 39 | assert rv.data == b"" |
| 40 | |
| 41 | |
| 42 | def test_options_on_multiple_rules(app, client): |