Please just work tests

This commit is contained in:
Andrew Kingston 2024-09-27 09:19:42 +01:00
parent b53bc5dfaf
commit 80f1de27de
No known key found for this signature in database
1 changed files with 12 additions and 0 deletions

View File

@ -125,6 +125,12 @@ describe("/permission", () => {
}) })
it("should be able to access the view data when the table is set to public and with no view permissions overrides", async () => { it("should be able to access the view data when the table is set to public and with no view permissions overrides", async () => {
// Make view inherit table permissions
await config.api.permission.revoke({
roleId: STD_ROLE_ID,
resourceId: view.id,
level: PermissionLevel.READ,
})
// replicate changes before checking permissions // replicate changes before checking permissions
await config.publish() await config.publish()
@ -138,6 +144,12 @@ describe("/permission", () => {
resourceId: table._id, resourceId: table._id,
level: PermissionLevel.READ, level: PermissionLevel.READ,
}) })
// Make view inherit table permissions
await config.api.permission.revoke({
roleId: STD_ROLE_ID,
resourceId: view.id,
level: PermissionLevel.READ,
})
// replicate changes before checking permissions // replicate changes before checking permissions
await config.publish() await config.publish()