Fix test_write_wrapper_set_authorizer: use permissive callback instead of None

conn.set_authorizer(None) does not clear the authorizer - SQLite treats
None as an invalid callback. The denied state persists on the shared
write connection, causing subsequent non-deny test cases to fail.

Fixes test added in 8a315f3d.
This commit is contained in:
Simon Willison 2026-02-17 13:30:46 -08:00
commit 1c6c6d2e68

View file

@ -445,7 +445,7 @@ async def test_write_wrapper_set_authorizer(datasette, actor, table, should_deny
try:
yield
finally:
conn.set_authorizer(None)
conn.set_authorizer(lambda *args: sqlite3.SQLITE_OK)
return wrapper