]> BookStack Code Mirror - bookstack/blob - dev/docs/permission-scenario-testing.md
7cd7667d21c5821627f807795b1d729ed20b852e
[bookstack] / dev / docs / permission-scenario-testing.md
1 # Permission Scenario Testing
2
3 Due to complexity that can arise in the various combinations of permissions, this document details scenarios and their expected results.
4
5 Test cases are written ability abstract, since all abilities should act the same in theory. Functional test cases may test abilities separate due to implementation differences.
6
7 ## Cases
8
9 ### Entity Role Permissions
10
11 These are tests related to entity-level role-specific permission overrides.
12
13 #### entity_role_01 - Explicit allow
14
15 - Page permissions have inherit disabled.
16 - Role A has explicit page permission.
17 - User has Role A.
18
19 User should have page permission.
20
21 #### entity_role_02 - Explicit deny
22
23 - Page permissions have inherit disabled.
24 - Role A has explicit page permission.
25 - User has Role A.
26
27 User should not have permission.
28
29 #### entity_role_03 - Same level conflicting
30
31 - Page permissions have inherit disabled.
32 - Role A has explicit page permission.
33 - Role B has explicit blocked page permission.
34 - User has both Role A & B.
35
36 User should have page permission. Explicit grant overrides explicit deny at same level.
37