forked from orbit-oss/flask
Use recwarn everywhere
...instead of custom fixture. Also assert that no warnings are left over after the test.
This commit is contained in:
parent
047efac537
commit
d393597c50
5 changed files with 110 additions and 92 deletions
|
|
@ -1116,9 +1116,10 @@ def test_static_files():
|
|||
rv.close()
|
||||
|
||||
|
||||
def test_static_path_deprecated():
|
||||
with pytest.deprecated_call():
|
||||
app = flask.Flask(__name__, static_path='/foo')
|
||||
def test_static_path_deprecated(recwarn):
|
||||
app = flask.Flask(__name__, static_path='/foo')
|
||||
recwarn.pop(DeprecationWarning)
|
||||
|
||||
app.testing = True
|
||||
rv = app.test_client().get('/foo/index.html')
|
||||
assert rv.status_code == 200
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue