MCPcopy Create free account
hub / github.com/pallets/flask / test_open_resource_exceptions

Function test_open_resource_exceptions

tests/test_helpers.py:347–351  ·  view source on GitHub ↗
(mode)

Source from the content-addressed store, hash-verified

345
346@pytest.mark.parametrize("mode", ("w", "x", "a", "r+"))
347def test_open_resource_exceptions(mode):
348 app = flask.Flask(__name__)
349
350 with pytest.raises(ValueError):
351 app.open_resource("static/index.html", mode)
352
353
354@pytest.mark.parametrize("encoding", ("utf-8", "utf-16-le"))

Callers

nothing calls this directly

Calls 1

open_resourceMethod · 0.95

Tested by

no test coverage detected