mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Fix minor irritation with /-/allowed UI
This commit is contained in:
parent
7d9d7acb0b
commit
ee62bf9bdc
3 changed files with 32 additions and 28 deletions
|
|
@ -69,8 +69,12 @@ async def ds_with_permissions():
|
|||
("/-/allowed.json", 400, {"error"}),
|
||||
# Invalid action
|
||||
("/-/allowed.json?action=nonexistent", 404, {"error"}),
|
||||
# Unsupported action (valid but not in CANDIDATE_SQL)
|
||||
("/-/allowed.json?action=insert-row", 400, {"error"}),
|
||||
# Any valid action works, even if no permission rules exist for it
|
||||
(
|
||||
"/-/allowed.json?action=insert-row",
|
||||
200,
|
||||
{"action", "items", "total", "page"},
|
||||
),
|
||||
],
|
||||
)
|
||||
async def test_allowed_json_basic(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue