test: Cypress en Playwright e2e-suites voor login, agenda, cortex en verpleegrapportage
Configs voor beide runners, login via session caching, AI-chat mocks (SSE) voor deterministische Cortex-tests. Supabase local config toegevoegd. Auth-state en reports zijn gitignored. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
35
tests/cypress/cortex/command-center.cy.ts
Normal file
35
tests/cypress/cortex/command-center.cy.ts
Normal file
@@ -0,0 +1,35 @@
|
||||
describe('Cortex Command Center - UI', () => {
|
||||
beforeEach(() => {
|
||||
cy.login();
|
||||
cy.visit('/epd/cortex');
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').should('be.visible');
|
||||
});
|
||||
|
||||
it('laadt de command center interface', () => {
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').should('be.visible');
|
||||
cy.contains('Welkom bij Cortex Assistent').first().should('be.visible');
|
||||
});
|
||||
|
||||
it('chat input accepteert tekst', () => {
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').type('test invoer');
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').should('have.value', 'test invoer');
|
||||
});
|
||||
|
||||
it('keyboard shortcut ⌘K focust de input', () => {
|
||||
cy.get('body').click();
|
||||
cy.get('body').type('{meta}k');
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').should('be.focused');
|
||||
});
|
||||
|
||||
it('escape wist de input', () => {
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').type('iets typen');
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').type('{esc}');
|
||||
cy.get('textarea[placeholder="Typ of spreek wat je wilt doen..."]:first').should('have.value', '');
|
||||
});
|
||||
|
||||
it('toont voorbeeldcommandos in de empty state', () => {
|
||||
cy.contains('Dagnotitie maken').first().should('be.visible');
|
||||
cy.contains('Patiënt zoeken').first().should('be.visible');
|
||||
cy.contains('Overdracht maken').first().should('be.visible');
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user