ATS-CRM-REG-013Restrict regional work to authorised users: Acceptance Test Set
MarkdownRestrict regional work to authorised users: Acceptance Test Set
Coverage
Test Scenarios
6 scenarios proving CAP-CRM-REG-013; 5 bound to an existing test.
01 Route declarations identify the required authorityunitnegativetest
- Proves
BR-CAP-CRM-REG-013-01 BR-CAP-CRM-REG-013-03 - Preconditions
- The regional route catalogue is available.
- Steps
- Inspect regional operation access and permissions.
- Expected
- The catalogue associates read, create, update, delete and recalculate work with their corresponding keys and console access.
- Data
- Published regional route metadata.
- Bound to
- Source
- services-crm:tests/unit/regions-authorization.spec.ts#requires crm.regions.read to list regions
03 Authentication and workspace access are requiredapinegativetest
- Proves
BR-CAP-CRM-REG-013-04 - Preconditions
- A regional record exists.
- Steps
- Request it anonymously and with access only to another workspace.
- Expected
- The responses reject unauthenticated and out-of-scope access.
- Data
- Authenticated and out-of-scope execution contexts.
- Bound to
- Source
- services-crm:modules/regions/tests/e2e/regions.e2e.spec.js#answers 401 to an anonymous call
04 Read-only views have no usable editsbrowsertest
- Proves
BR-CAP-CRM-REG-013-05 - Preconditions
- The signed-in user has read-only authority.
- Steps
- Visit both regional tabs.
- Expected
- The view explains read-only access and provides no usable Add, Edit, Delete or Recalculate actions.
- Data
- An identity limited to read authority.
- Bound to
- Source
- react-console:e2e/dev/regions.dev.spec.ts#shows a read-only user the regions, and offers them nothing that changes one
05 Partial aliases expose mismatched controlsbrowsernegativeproposed
- Proves
BR-CAP-CRM-REG-013-07 - Preconditions
- Users separately hold regional create, contact-role update and contact-role read authority.
- Steps
- Visit Regions and attempt a policy save with each authority set.
- Expected
- Record the controls exposed and the regional requests refused by the service.
- Data
- Three policies exposing the partial-key combinations.
- Source
- react-console:lib/authz/backend-aliases.ts:crm.settings.view, crm.settings.manage, maintenance.operations.run
06 Read permits listing but cannot create rulesapinegativetest
- Proves
BR-CAP-CRM-REG-013-08 - Preconditions
- The caller holds regional read alone.
- Steps
- List rules and submit rule creation.
- Expected
- Listing succeeds and creation is denied.
- Data
- Execution limited to regional reading.
- Bound to
- Source
- services-crm:modules/regions/tests/e2e/regions.e2e.spec.js#the rules, one at a time › answers 200 to a list for a context carrying only the read permission