Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion tests/e2e/workflows/crud-persistence.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,11 @@ test.beforeEach(({ page }) => {
// That error aborts the WHOLE SUITE before a single test runs — 0 collected, no
// tally, and the failure names this file rather than anything under test. `{}`
// is the documented way to say "no fixtures, but give me testInfo".
test.afterEach(async (_fixtures, testInfo) => {
// eslint-disable-next-line no-empty-pattern -- Playwright resolves fixtures
// BY NAME from this pattern, and `{}` is its documented way to say "no
// fixtures, but give me testInfo". Naming it (`_fixtures`) makes Playwright
// look for a fixture called _fixtures and refuse the whole file.
test.afterEach(async ({}, testInfo) => {
if (testInfo.status === testInfo.expectedStatus) return
const dump = traffic
.map((c) =>
Expand Down
16 changes: 4 additions & 12 deletions tests/e2e/workflows/rbac-authorization-workflow.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,7 @@ const ADMIN_GATED_ENDPOINTS = [
]

test.describe('consume-or-rbac-authorization — who-may-act preserved via OR RBAC', () => {
test('a signatory may initiate signing; a non-signatory is denied (403)', async ({
_page,
}) => {
test('a signatory may initiate signing; a non-signatory is denied (403)', async () => {
// Deferred live run: requires decidiq deployed with a Minutes record on a
// body whose signatory scope (decidesk:body:{id}:signatory) is populated by
// the role projector. A signatory's POST to
Expand All @@ -81,9 +79,7 @@ test.describe('consume-or-rbac-authorization — who-may-act preserved via OR RB
expect(BASE).toBeTruthy()
})

test('only the chair may run a chair-only lifecycle transition', async ({
_page,
}) => {
test('only the chair may run a chair-only lifecycle transition', async () => {
// Deferred live run: a chair-only transition (e.g. legislative opened→adjourned)
// succeeds for a member of decidesk:body:{id}:chair and is refused for a
// non-chair with "Only the meeting chair may perform this transition."
Expand All @@ -96,9 +92,7 @@ test.describe('consume-or-rbac-authorization — who-may-act preserved via OR RB
expect(BASE).toBeTruthy()
})

test('a disallowed domain transition is refused independent of actor scope', async ({
_page,
}) => {
test('a disallowed domain transition is refused independent of actor scope', async () => {
// Deferred live run: a domain whose workflow sets allowPause:false refuses
// opened→paused for the chair too (workflow policy, not actor auth). Asserted
// at unit level in MeetingServiceTest testDomainDisallowedTransitionReturnsFailure.
Expand All @@ -109,9 +103,7 @@ test.describe('consume-or-rbac-authorization — who-may-act preserved via OR RB
expect(BASE).toBeTruthy()
})

test('a non-admin is denied on every previously admin-gated surface; an admin is allowed', async ({
_page,
}) => {
test('a non-admin is denied on every previously admin-gated surface; an admin is allowed', async () => {
// Deferred live run: as a non-admin, each ADMIN_GATED_ENDPOINTS call returns
// 401/403 from the shared RequiresOrAdmin trait; as an admin each is permitted.
// Asserted at unit level in AuditLogControllerTest (admin allow / non-admin deny).
Expand Down
Loading