mirror of
https://dev.azure.com/globalhealthx/EMR/_git/helix-engage
synced 2026-04-11 18:28:15 +00:00
feat: add E2E smoke tests, architecture docs, and operations runbook
- 27 Playwright E2E tests covering login (3 roles), CC Agent pages (call desk, call history, patients, appointments, my performance, sidebar, sign-out), and Supervisor pages (all 11 pages + sidebar) - Tests run against live EC2 at ramaiah.engage.healix360.net - Last test completes sign-out to release agent session for next run - Architecture doc with updated Mermaid diagram including telephony dispatcher, service discovery, and multi-tenant topology - Operations runbook with SSH access (VPS + EC2), accounts, container reference, deploy steps, Redis ops, and troubleshooting guide Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
22
e2e/auth.setup.ts
Normal file
22
e2e/auth.setup.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
import { test as setup, expect } from '@playwright/test';
|
||||
import path from 'path';
|
||||
import { fileURLToPath } from 'url';
|
||||
|
||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||
const authFile = path.join(__dirname, '.auth/agent.json');
|
||||
|
||||
setup('login as CC Agent', async ({ page }) => {
|
||||
await page.goto('/login');
|
||||
|
||||
await page.locator('input[type="email"], input[name="email"], input[placeholder*="@"]').first().fill('ccagent@ramaiahcare.com');
|
||||
await page.locator('input[type="password"]').first().fill('CcRamaiah@2026');
|
||||
await page.getByRole('button', { name: 'Sign in', exact: true }).click();
|
||||
|
||||
// Should land on Call Desk (/ for cc-agent role)
|
||||
await expect(page).not.toHaveURL(/\/login/, { timeout: 20_000 });
|
||||
|
||||
// Sidebar should be visible
|
||||
await expect(page.locator('aside').first()).toBeVisible({ timeout: 10_000 });
|
||||
|
||||
await page.context().storageState({ path: authFile });
|
||||
});
|
||||
Reference in New Issue
Block a user