Try more aggressive noqa, refs #291

This commit is contained in:
Simon Willison 2021-06-22 19:06:18 -07:00
commit 1fba60537d

View file

@ -55,14 +55,14 @@ def test_register_function_replace(fresh_db):
# This will fail to replace the function:
@fresh_db.register_function()
def one(): # noqa: F811
def one(): # noqa
return "two"
assert "one" == fresh_db.execute("select one()").fetchone()[0]
# This will replace it
@fresh_db.register_function(replace=True)
def one(): # noqa: F811
def one(): # noqa
return "two"
assert "two" == fresh_db.execute("select one()").fetchone()[0]