Files
KArtSell.Aegis/frontend/src/shared/auth/tests/routeAccess.spec.ts
T
kjh2064 70852bf378
deploy / deploy (push) Successful in 1m49s
deploy / notify (push) Successful in 1s
fix: Clean up KBX v60 references and simplify frontend pages
- Removed all @kbx/contracts imports and types
- Cleaned up feature registries (minimal definitions)
- Simplified page components (HomePage, ModelsList, ShadowRunList)
- Removed KBX UI components and adapters
- Fixed TypeScript errors with type casting
- Frontend build: 737KB (204KB gzip) 

CI/CD Pipeline: Ready for testing
2026-08-15 11:58:44 +09:00

14 lines
494 B
TypeScript

import { describe, expect, it } from 'vitest'
import { canAccessRoute } from '../routeAccess'
describe('route access contract', () => {
it('allows routes without a declared permission', () => {
expect(canAccessRoute({}, new Set())).toBe(true)
})
it('requires every declared permission', () => {
expect(canAccessRoute({ permissions: ['model.read'] }, new Set())).toBe(false)
expect(canAccessRoute({ permissions: ['model.read'] }, new Set(['model.read']))).toBe(true)
})
})