(app, client)
| 40 | |
| 41 | |
| 42 | def test_options_on_multiple_rules(app, client): |
| 43 | @app.route("/", methods=["GET", "POST"]) |
| 44 | def index(): |
| 45 | return "Hello World" |
| 46 | |
| 47 | @app.route("/", methods=["PUT"]) |
| 48 | def index_put(): |
| 49 | return "Aha!" |
| 50 | |
| 51 | rv = client.open("/", method="OPTIONS") |
| 52 | assert sorted(rv.allow) == ["GET", "HEAD", "OPTIONS", "POST", "PUT"] |
| 53 | |
| 54 | |
| 55 | @pytest.mark.parametrize("method", ["get", "post", "put", "delete", "patch"]) |
nothing calls this directly
no test coverage detected
searching dependent graphs…