Updating test case.

This commit is contained in:
mike12345567 2024-10-22 16:04:18 +01:00
parent 74870663e2
commit 99d867fe60
1 changed files with 3 additions and 5 deletions

View File

@ -165,11 +165,9 @@ describe("/roles", () => {
...basicRole(), ...basicRole(),
inherits: [BUILTIN_ROLE_IDS.ADMIN], inherits: [BUILTIN_ROLE_IDS.ADMIN],
}) })
// save again // remove the roles so that it will default back to DB roles, then save again
const updatedRes = await config.api.roles.save({ delete res.inherits
...res, const updatedRes = await config.api.roles.save(res)
inherits: undefined,
})
expect(updatedRes.inherits).toEqual([BUILTIN_ROLE_IDS.ADMIN]) expect(updatedRes.inherits).toEqual([BUILTIN_ROLE_IDS.ADMIN])
}) })
}) })