Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure
TypeScript
test(qa-recorder): add conflict, removed-access, and search-by-agent journeys
Miguelon Peluchonc226545bf0a2
diff --git a/control-ui/e2e/qa-recorder-agent-connectors-conflict.spec.ts b/control-ui/e2e/qa-recorder-agent-connectors-conflict.spec.tsnew file mode 100644index 000000000..53a383ecf--- /dev/null+++ b/control-ui/e2e/qa-recorder-agent-connectors-conflict.spec.ts@@ -0,0 +1,206 @@+// control-ui/e2e/qa-recorder-agent-connectors-conflict.spec.ts+//+// Optional QA recorder journey (MUTATING). Requires QA_RECORDER_CONFIRM_MUTATIONS=1.+// Video-tours the optimistic-concurrency guard on the agent Connectors tab:+// the page loads a context resourceVersion, an out-of-band Control API PUT+// bumps that version behind the page's back, and the next "Add connector"+// save fails with HTTP 409 — surfacing the reload-guidance error banner+// instead of silently overwriting the winner. Reloading the page picks up+// the fresh resourceVersion and the retried add lands ("Connectors+// updated."). The seeded context, MCP servers, and host are deleted via the+// Control API in a finally (host first, then servers and context).+//+// Contract: docs/testing/optional-playwright-qa-recorder.md ("Extending the recorder").+import { expect, test } from '@playwright/test'+import {+ CONTROL_API_URL,+ CONTROL_UI_URL,+ adminCredentials,+ api,+ assertAllowedTarget,+ loginThroughUi,+ requireRecorderConfirm,+ screenshotAndLog,+ uniqueE2EName,+} from './qa-recorder-helpers'++type ContextRead = {+ metadata?: { resourceVersion?: string }+ spec?: Record<string, unknown>+}++// The single-resource GET returns the bare Context; tolerate an `{ item }`+// envelope so the journey survives either wire shape.+type ContextReadEnvelope = ContextRead & { item?: ContextRead }++test.describe('optional QA recorder: Control UI agent connectors conflict', () => {+ test('optional QA recorder: Control UI agent connectors conflict journey', async ({+ page,+ }, testInfo) => {+ requireRecorderConfirm(+ 'QA_RECORDER_CONFIRM_MUTATIONS',+ 'This journey creates and deletes a context, MCP servers, and a host.'+ )+ assertAllowedTarget('CONTROL_UI_URL', CONTROL_UI_URL)+ assertAllowedTarget('CONTROL_API_URL', CONTROL_API_URL)++ const credentials = adminCredentials()+ const agentName = uniqueE2EName('qa-agent-conflict-host')+ const contextName = uniqueE2EName('qa-agent-conflict-ctx')+ // The context starts with no servers so both seeded catalog servers are+ // pickable in the "Add connector" dialog on every retry.+ const serverOne = uniqueE2EName('qa-agent-conflict-srv-a')+ const serverTwo = uniqueE2EName('qa-agent-conflict-srv-b')++ async function createMcpServer(serverName: string): Promise<void> {+ const res = await api(page.request, 'POST', '/api/v1/admin/mcp-servers', {+ metadata: { name: serverName },+ spec: {+ image: 'clerum/mock-mcp-server:test',+ contextRef: contextName,+ enabled: true,+ managed: true,+ transport: {+ type: 'streamableHttp',+ port: 3000,+ url: `http://${serverName}.mcp-server.svc.cluster.local:3000/mcp`,+ },+ },+ })+ expect(res.status, `create mcp-server: ${JSON.stringify(res.data)}`).toBeLessThan(300)+ }++ try {+ await loginThroughUi(page, credentials)++ // Seed: empty context, two catalog servers, and the host bound to the+ // context.+ const ctxRes = await api(page.request, 'POST', '/api/v1/admin/contexts', {+ metadata: { name: contextName },+ spec: {+ contextId: contextName,+ description: `QA recorder agent-connectors conflict fixture for ${agentName}`,+ mcpServers: [],+ },+ })+ expect(ctxRes.status, `create context: ${JSON.stringify(ctxRes.data)}`).toBeLessThan(300)++ for (const serverName of [serverOne, serverTwo]) {+ await createMcpServer(serverName)+ }++ const hostRes = await api(page.request, 'POST', '/api/v1/admin/hosts', {+ metadata: { name: agentName },+ spec: {+ host: agentName,+ contextRef: contextName,+ secretRef: '',+ channels: [],+ model: { provider: 'openai', name: 'gpt-5.4-mini' },+ },+ })+ expect(hostRes.status, `create host: ${JSON.stringify(hostRes.data)}`).toBeLessThan(300)++ // Open the agent's Connectors tab. The empty-state cell proves the+ // context (and its resourceVersion) finished loading before the dialog+ // opens.+ await page.goto(`${CONTROL_UI_URL}/agents/${agentName}/connectors`)+ await expect(page.getByText(`Agent: ${agentName}`)).toBeVisible({ timeout: 20_000 })+ await expect(page.getByText('No connectors attached yet.')).toBeVisible({ timeout: 20_000 })++ // Open the "Add connector" dialog — this loads the available servers+ // but does NOT submit yet.+ await page.getByRole('button', { name: 'Add connector', exact: true }).click()+ const dialog = page.getByRole('dialog', { name: 'Add connectors' })+ await expect(dialog).toBeVisible({ timeout: 20_000 })+ await expect(dialog.getByRole('option', { name: serverOne, exact: true })).toBeVisible({+ timeout: 20_000,+ })++ // Mutate the context out-of-band: a fresh GET carries the current+ // resourceVersion, and ONE same-spec PUT bumps it server-side, so the+ // version the page loaded is now stale.+ const currentRes = await api<ContextReadEnvelope>(+ page.request,+ 'GET',+ `/api/v1/admin/contexts/${encodeURIComponent(contextName)}`+ )+ expect(currentRes.status, `get context: ${JSON.stringify(currentRes.data)}`).toBe(200)+ const currentContext = currentRes.data.item ?? currentRes.data+ const resourceVersion = String(currentContext.metadata?.resourceVersion || '')+ expect(resourceVersion, 'context resourceVersion before the out-of-band PUT').toBeTruthy()+ const bumpRes = await api(+ page.request,+ 'PUT',+ `/api/v1/admin/contexts/${encodeURIComponent(contextName)}`,+ {+ metadata: { resourceVersion },+ spec: currentContext.spec ?? {},+ }+ )+ expect(+ bumpRes.status,+ `out-of-band context PUT: ${JSON.stringify(bumpRes.data)}`+ ).toBeLessThan(300)++ // Back in the UI, pick an option and confirm. The dialog's confirm+ // button repeats the page-level opener's "Add connector" label, so the+ // lookup stays scoped to the dialog.+ await dialog.getByRole('option', { name: serverOne, exact: true }).click()+ await dialog.getByRole('button', { name: 'Add connector', exact: true }).click()++ // The save 409s: the error banner shows the reload guidance at the top+ // of the page, and the dialog stays open with the draft preserved.+ await expect(+ page.locator('.cu-banner--error').filter({+ hasText:+ 'This agent’s connectors changed since they were loaded. Reload the agent and try again.',+ })+ ).toBeVisible({ timeout: 20_000 })+ await expect(dialog).toBeVisible()+ await expect(page.getByText('Connectors updated.')).toHaveCount(0)+ await screenshotAndLog(page, testInfo, 'agent-connectors-conflict-banner')++ // Recovery: reloading the page picks up the fresh resourceVersion.+ await page.reload()+ await expect(page.getByText(`Agent: ${agentName}`)).toBeVisible({ timeout: 20_000 })+ await expect(page.getByText('No connectors attached yet.')).toBeVisible({ timeout: 20_000 })++ // The retried add succeeds.+ await page.getByRole('button', { name: 'Add connector', exact: true }).click()+ const retryDialog = page.getByRole('dialog', { name: 'Add connectors' })+ await expect(retryDialog).toBeVisible({ timeout: 20_000 })+ await retryDialog.getByRole('option', { name: serverOne, exact: true }).click()+ await retryDialog.getByRole('button', { name: 'Add connector', exact: true }).click()++ await expect(page.getByText('Connectors updated.')).toBeVisible({ timeout: 20_000 })+ await expect(page.getByRole('row', { name: new RegExp(serverOne) })).toBeVisible({+ timeout: 20_000,+ })+ await screenshotAndLog(page, testInfo, 'agent-connectors-conflict-recovered')+ } finally {+ // Best-effort cleanup; the disposable environment tolerates leftovers.+ // The host must go before its context.+ try {+ await api(page.request, 'DELETE', `/api/v1/admin/hosts/${encodeURIComponent(agentName)}`)+ await api(+ page.request,+ 'DELETE',+ `/api/v1/admin/mcp-servers/${encodeURIComponent(serverOne)}`+ )+ await api(+ page.request,+ 'DELETE',+ `/api/v1/admin/mcp-servers/${encodeURIComponent(serverTwo)}`+ )+ await api(+ page.request,+ 'DELETE',+ `/api/v1/admin/contexts/${encodeURIComponent(contextName)}`+ )+ } catch {+ // Ignore cleanup failures.+ }+ }+ })+})diff --git a/control-ui/e2e/qa-recorder-connectors-search-agent.spec.ts b/control-ui/e2e/qa-recorder-connectors-search-agent.spec.tsnew file mode 100644index 000000000..195cbb974--- /dev/null+++ b/control-ui/e2e/qa-recorder-connectors-search-agent.spec.ts@@ -0,0 +1,144 @@+// control-ui/e2e/qa-recorder-connectors-search-agent.spec.ts+//+// Optional QA recorder journey (MUTATING). Requires QA_RECORDER_CONFIRM_MUTATIONS=1.+// Video-tours the Installed Connectors search box: typing an agent display+// name keeps the agent's connector row visible (access principals are part+// of the search haystack), a nonsense string lands the "No connectors match+// this search." empty state, and clearing the search restores the row. The+// private context slug backing the row never appears in the page body. The+// seeded server, host, and context are deleted via the Control API in a+// finally (server and host before the context).+//+// Contract: docs/testing/optional-playwright-qa-recorder.md ("Extending the recorder").+import { expect, test } from '@playwright/test'+import {+ CONTROL_API_URL,+ CONTROL_UI_URL,+ adminCredentials,+ api,+ assertAllowedTarget,+ loginThroughUi,+ requireRecorderConfirm,+ screenshotAndLog,+ uniqueE2EName,+} from './qa-recorder-helpers'++test.describe('optional QA recorder: Control UI connectors search by agent', () => {+ test('optional QA recorder: Control UI connectors search by agent journey', async ({+ page,+ }, testInfo) => {+ requireRecorderConfirm(+ 'QA_RECORDER_CONFIRM_MUTATIONS',+ 'This journey creates and deletes an MCP server, host, and context.'+ )+ assertAllowedTarget('CONTROL_UI_URL', CONTROL_UI_URL)+ assertAllowedTarget('CONTROL_API_URL', CONTROL_API_URL)++ const credentials = adminCredentials()+ const journey = 'control-ui-connectors-search-agent'+ const serverName = uniqueE2EName('qa-csa-srv')+ const contextName = uniqueE2EName('qa-csa-ctx')+ const agentName = uniqueE2EName('qa-csa-agent')+ const noMatchQuery = uniqueE2EName('qa-csa-nomatch')++ try {+ await loginThroughUi(page, credentials)++ // Seed: one server carried by a private context bound to one agent —+ // the agent display name is an access principal on the connector row.+ const serverRes = await api(page.request, 'POST', '/api/v1/admin/mcp-servers', {+ metadata: { name: serverName },+ spec: {+ image: 'clerum/mock-mcp-server:test',+ contextRef: contextName,+ enabled: true,+ managed: true,+ transport: {+ type: 'streamableHttp',+ port: 3000,+ url: `http://${serverName}.mcp-server.svc.cluster.local:3000/mcp`,+ },+ },+ })+ expect(serverRes.status, `create mcp-server: ${JSON.stringify(serverRes.data)}`).toBeLessThan(+ 300+ )++ const ctxRes = await api(page.request, 'POST', '/api/v1/admin/contexts', {+ metadata: { name: contextName },+ spec: {+ contextId: contextName,+ description: 'QA recorder connectors search fixture',+ mcpServers: [serverName],+ },+ })+ expect(ctxRes.status, `create context: ${JSON.stringify(ctxRes.data)}`).toBeLessThan(300)++ const hostRes = await api(page.request, 'POST', '/api/v1/admin/hosts', {+ metadata: { name: agentName },+ spec: {+ host: agentName,+ contextRef: contextName,+ secretRef: '',+ channels: [],+ model: { provider: 'openai', name: 'gpt-5.4-mini' },+ },+ })+ expect(hostRes.status, `create host: ${JSON.stringify(hostRes.data)}`).toBeLessThan(300)++ await page.getByRole('link', { name: 'Installed Connectors', exact: true }).click()+ await expect(page).toHaveURL(/\/connectors\/?$/, { timeout: 20_000 })+ await expect(+ page.getByText('Browse connector deployments and agent access.', { exact: true })+ ).toBeVisible({ timeout: 20_000 })++ const row = page.getByRole('row', { name: new RegExp(serverName) })+ await expect(row).toBeVisible({ timeout: 20_000 })++ // Typing the agent display name keeps the row: access principals are+ // part of the search haystack.+ const search = page.getByRole('searchbox', { name: 'Search connectors' })+ await search.fill(agentName)+ await expect(row).toBeVisible({ timeout: 20_000 })+ await screenshotAndLog(page, testInfo, `${journey}-by-agent`)++ // A nonsense string matches nothing — the search empty state, not the+ // unfiltered table.+ await search.fill(noMatchQuery)+ await expect(row).toHaveCount(0)+ await expect(page.getByText('No connectors match this search.', { exact: true })).toBeVisible(+ {+ timeout: 20_000,+ }+ )+ await screenshotAndLog(page, testInfo, `${journey}-no-match`)++ // Clearing the search restores the row.+ await search.clear()+ await expect(row).toBeVisible({ timeout: 20_000 })++ // The private context slug is an implementation detail — never rendered.+ const bodyText = await page.innerText('body')+ expect(bodyText).not.toContain(contextName)+ await screenshotAndLog(page, testInfo, `${journey}-cleared`)+ } finally {+ // Best-effort cleanup; the disposable environment tolerates leftovers.+ // The server and host must go before the context.+ try {+ await api(+ page.request,+ 'DELETE',+ `/api/v1/admin/mcp-servers/${encodeURIComponent(serverName)}`+ )+ await api(page.request, 'DELETE', `/api/v1/admin/hosts/${encodeURIComponent(agentName)}`)+ await api(+ page.request,+ 'DELETE',+ `/api/v1/admin/contexts/${encodeURIComponent(contextName)}`+ )+ } catch {+ // Ignore cleanup failures.+ }+ }+ })+})diff --git a/control-ui/e2e/qa-recorder-member-removed-access.spec.ts b/control-ui/e2e/qa-recorder-member-removed-access.spec.tsnew file mode 100644index 000000000..061dc8403--- /dev/null+++ b/control-ui/e2e/qa-recorder-member-removed-access.spec.ts@@ -0,0 +1,174 @@+// control-ui/e2e/qa-recorder-member-removed-access.spec.ts+//+// Optional QA recorder journey (MUTATING). Requires QA_RECORDER_CONFIRM_MUTATIONS=1.+// Video-tours the member Access tab's tombstone story: a scope granted to a+// member whose backing Context is then deleted out-of-band renders under the+// "Removed access" heading (cu-deleted-access-heading) with the resolved+// agent display name and a "Deleted" marker — never a bare contextId row in+// the active table. The member's original contextIds are restored via PUT+// and the seeded host is deleted in the finally; the Context stays deleted+// (it is the journey's fixture), so it is never deleted twice.+//+// Contract: docs/testing/optional-playwright-qa-recorder.md ("Extending the+// recorder").+import { expect, test } from '@playwright/test'+import {+ CONTROL_API_URL,+ CONTROL_UI_URL,+ adminCredentials,+ api,+ assertAllowedTarget,+ loginThroughUi,+ requireRecorderConfirm,+ screenshotAndLog,+ uniqueE2EName,+} from './qa-recorder-helpers'++test.describe('optional QA recorder: Control UI member removed access', () => {+ test('optional QA recorder: Control UI member removed access journey', async ({+ page,+ }, testInfo) => {+ requireRecorderConfirm(+ 'QA_RECORDER_CONFIRM_MUTATIONS',+ 'This journey grants member access, deletes the backing context, and seeds/deletes a host.'+ )+ assertAllowedTarget('CONTROL_UI_URL', CONTROL_UI_URL)+ assertAllowedTarget('CONTROL_API_URL', CONTROL_API_URL)++ const credentials = adminCredentials()+ const journey = 'control-ui-member-removed-access'+ const contextName = uniqueE2EName('qa-member-removed-ctx')+ const contextId = uniqueE2EName('qa-member-removed-scope')+ const hostName = uniqueE2EName('qa-member-removed-host')+ const hostDisplayName = uniqueE2EName('qa-member-removed-agent')+ let userId = ''+ let originalContextIds: string[] | null = null+ let restored = false++ try {+ await loginThroughUi(page, credentials)++ // First member from the directory carries the journey.+ const usersRes = await api<{ items?: Array<{ id: string }> }>(+ page.request,+ 'GET',+ '/api/v1/admin/users'+ )+ expect(usersRes.status, `list users: ${JSON.stringify(usersRes.data)}`).toBe(200)+ test.skip(+ (usersRes.data.items ?? []).length === 0,+ 'No users seeded in this environment; skipping member removed access journey.'+ )+ userId = String(usersRes.data.items?.[0]?.id || '')+ expect(userId, 'first user id').toBeTruthy()++ // Remember the member's original contextIds before granting anything.+ const originalRes = await api<{ contextIds?: string[] }>(+ page.request,+ 'GET',+ `/api/v1/admin/users/${encodeURIComponent(userId)}/contexts`+ )+ expect(+ originalRes.status,+ `get user contexts: ${JSON.stringify(originalRes.data)}`+ ).toBeLessThan(300)+ originalContextIds = originalRes.data.contextIds ?? []++ // Seed: a host-backed scope, granted to the member.+ const ctxRes = await api(page.request, 'POST', '/api/v1/admin/contexts', {+ metadata: { name: contextName },+ spec: {+ contextId,+ description: 'QA recorder member removed access scope',+ mcpServers: [],+ },+ })+ expect(ctxRes.status, `create context: ${JSON.stringify(ctxRes.data)}`).toBeLessThan(300)++ const hostRes = await api(page.request, 'POST', '/api/v1/admin/hosts', {+ metadata: { name: hostName },+ spec: {+ host: hostDisplayName,+ contextRef: contextId,+ secretRef: '',+ channels: [],+ model: { provider: 'openai', name: 'gpt-5.4-mini' },+ },+ })+ expect(hostRes.status, `create host: ${JSON.stringify(hostRes.data)}`).toBeLessThan(300)++ const grantRes = await api(+ page.request,+ 'PUT',+ `/api/v1/admin/users/${encodeURIComponent(userId)}/contexts`,+ { contextIds: [...originalContextIds, contextId] }+ )+ expect(grantRes.status, `grant user contexts: ${JSON.stringify(grantRes.data)}`).toBeLessThan(+ 300+ )++ // Delete the backing context out-of-band. The host stays alive so the+ // tombstoned row can still resolve to the agent display name.+ const deleteRes = await api(+ page.request,+ 'DELETE',+ `/api/v1/admin/contexts/${encodeURIComponent(contextName)}`+ )+ expect(deleteRes.status, `delete context: ${JSON.stringify(deleteRes.data)}`).toBeLessThan(+ 300+ )++ // The Access tab renders the orphaned mapping under "Removed access".+ await page.goto(+ `${CONTROL_UI_URL}/users-and-teams/users/${encodeURIComponent(userId)}/access`+ )+ await expect(+ page.getByText('Agents and connector scopes this member may access.', { exact: true })+ ).toBeVisible({ timeout: 20_000 })++ await expect(+ page.locator('.cu-deleted-access-heading').filter({ hasText: 'Removed access' })+ ).toBeVisible({ timeout: 20_000 })++ const removedRow = page+ .getByRole('row')+ .filter({ has: page.getByRole('cell', { name: hostDisplayName, exact: true }) })+ await expect(removedRow).toBeVisible({ timeout: 20_000 })+ await expect(removedRow.getByText('Deleted', { exact: true })).toBeVisible()+ // The raw wire contextId never renders for the tombstone.+ await expect(removedRow).not.toContainText(contextId)+ await screenshotAndLog(page, testInfo, `${journey}-deleted-scope`)++ // Restore: the member's original contextIds, which never contained the+ // deleted scope. A lingering deletedContextIds entry is server-side+ // bookkeeping and fine to leave behind.+ const restoreRes = await api(+ page.request,+ 'PUT',+ `/api/v1/admin/users/${encodeURIComponent(userId)}/contexts`,+ { contextIds: originalContextIds }+ )+ expect(+ restoreRes.status,+ `restore user contexts: ${JSON.stringify(restoreRes.data)}`+ ).toBeLessThan(300)+ restored = true+ } finally {+ // Best-effort cleanup. The context is already deleted — never delete it+ // again. Restore the member's grants only if the body never got to.+ try {+ if (userId && originalContextIds !== null && !restored) {+ await api(+ page.request,+ 'PUT',+ `/api/v1/admin/users/${encodeURIComponent(userId)}/contexts`,+ { contextIds: originalContextIds }+ )+ }+ await api(page.request, 'DELETE', `/api/v1/admin/hosts/${encodeURIComponent(hostName)}`)+ } catch {+ // Ignore cleanup failures.+ }+ }+ })+})diff --git a/control-ui/package-lock.json b/control-ui/package-lock.jsonindex 4f7c2c87d..459efda58 100644--- a/control-ui/package-lock.json+++ b/control-ui/package-lock.json@@ -1,12 +1,12 @@{"name": "clerum-control-ui",- "version": "0.1.465",+ "version": "0.1.466","lockfileVersion": 3,"requires": true,"packages": {"": {"name": "clerum-control-ui",- "version": "0.1.465",+ "version": "0.1.466","dependencies": {"@clerum/display-field": "file:../packages/display-field","@clerum/llm-providers": "file:../packages/llm-providers",diff --git a/control-ui/package.json b/control-ui/package.jsonindex c3692f02f..e64bc61ba 100644--- a/control-ui/package.json+++ b/control-ui/package.json@@ -1,6 +1,6 @@{"name": "clerum-control-ui",- "version": "0.1.465",+ "version": "0.1.466","private": true,"scripts": {"dev": "NEXT_IGNORE_INCORRECT_LOCKFILE=1 next dev",@@ -51,6 +51,9 @@"qa:recorder:recipe-scope-copy": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts qa-recorder-recipe-scope-copy.spec.ts","qa:recorder:token-budget-scope": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts qa-recorder-token-budget-scope.spec.ts","qa:recorder:context-vocab-sweep": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts qa-recorder-context-vocab-sweep.spec.ts",+ "qa:recorder:agent-connectors-conflict": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts qa-recorder-agent-connectors-conflict.spec.ts",+ "qa:recorder:member-removed-access": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts qa-recorder-member-removed-access.spec.ts",+ "qa:recorder:connectors-search-agent": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts qa-recorder-connectors-search-agent.spec.ts","qa:recorder:all": "PLAYWRIGHT_BROWSERS_PATH=../.local-notes/qa-recorder/browsers playwright test --config=playwright.qa-recorder.config.ts","test": "vitest run","test:watch": "vitest"diff --git a/docs/features/control-ui-context-removal.md b/docs/features/control-ui-context-removal.mdindex b87d03053..50a5197a9 100644--- a/docs/features/control-ui-context-removal.md+++ b/docs/features/control-ui-context-removal.md@@ -232,6 +232,9 @@ Tests updated in the same commit: `HostTable.test.tsx` (hover card now asserts a| `qa:recorder:recipe-scope-copy` | G1–G2 | yes || `qa:recorder:token-budget-scope` | G3 | yes || `qa:recorder:context-vocab-sweep` | Global negative check, 8 routes | no |+ | `qa:recorder:agent-connectors-conflict` | B4 error path: out-of-band 409 → "This agent's connectors changed…" banner + reload-recover | yes |+ | `qa:recorder:member-removed-access` | "Removed access" section for a mapping whose scope was deleted | yes |+ | `qa:recorder:connectors-search-agent` | Connectors search filters by agent display name | yes |Prerequisites for video evidence: `npm run qa:recorder:install` (once), `make minikube-pf-all`, and a repo-root `.env.qa-recorder` copied from the committed `.env.qa-recorder.example` containing the admin identity (`E2E_ADMIN_USER`/`E2E_ADMIN_PASSWORD`) and `QA_RECORDER_CONFIRM_MUTATIONS=1` for the mutating journeys. Journeys follow the recorder contract (`docs/testing/optional-playwright-qa-recorder.md`): loopback-only target guard, explicit opt-in before any write, and full API cleanup in `finally`.- Verification per phase: `cd control-ui && npx tsc --noEmit && npm test` (no lint script exists in control-ui; typecheck via `tsc --noEmit`).@@ -251,6 +254,7 @@ Tests updated in the same commit: `HostTable.test.tsx` (hover card now asserts a| 2026-08-27 | docs | Source-of-truth restructured after the audit: added §11 (audit report: backend-untouched proof incl. the `origin/dev`-moved warning, leak/fix table, verified intentional remnants), §12 (full click-by-click manual tester walkthrough, tables A–G + global negative check), renumbered open questions to §13; extended the §2.5 exclusion list to the complete audited set; corrected §4 E1 (hover card shows a neutral "Connectors" heading, not the agent name) and the §6.4 heading typo. || 2026-08-27 | e2e | Built the full e2e regression catalog for the §12 flows: 15 new specs + `contexts.spec.ts` extended with the real-slug resolver case (112 tests / 24 files listed for the control-ui project). Extended `helpers/api-client.ts` with context/mcp-server/user-team-contexts/team/budget seeding + teardown helpers (all against the unchanged wire API). Added `tests/e2e/playwright/tsconfig.typecheck.json` so the package typechecks standalone (`npx tsc -p tsconfig.typecheck.json` → clean; the shipped tsconfig lacks node types + a covering rootDir). No specs executed here (no cluster) — they run under the normal `make test-playwright-control-ui` / T2 lane. control-ui unit suite re-verified 1700/1700. No backend changes. || 2026-08-27 | e2e | Built the QA-recorder video-evidence journeys: 11 new `qa-recorder-*` specs + `qa-recorder-connector-edit` extended with the legacy-tab redirect, each with a dedicated `qa:recorder:<name>` npm script (62 tests / 45 files listed under the recorder config). Journeys follow the recorder contract (loopback guard, `QA_RECORDER_CONFIRM_MUTATIONS` opt-in for mutating journeys, `screenshotAndLog` at every step, full API cleanup in `finally`). Committed the previously-missing `.env.qa-recorder.example` (referenced by the recorder doc but never tracked) with the exact keys the journeys need. Verification: control-ui `tsc --noEmit` clean, recorder `--list` clean, unit suite 1700/1700. No backend changes. |+| 2026-08-27 | e2e | Added 3 gap journeys for error/degraded paths: `agent-connectors-conflict` (out-of-band context PUT stales the page → 409 banner "This agent's connectors changed since they were loaded." → reload + retry succeeds), `member-removed-access` (mapping whose scope was deleted renders under "Removed access" with the agent label + Deleted marker), `connectors-search-agent` (search-by-agent-name filtering + empty state). Recorder catalog now 65 tests / 48 files listed; `tsc` clean. **Execution status: no Playwright spec (main or recorder) has been executed in this lane — no runnable cluster exists in the dev session** (both minikube profiles Stopped, no branch.mk ownership record → fail-closed per repo rules; the live `:3000` server belongs to the unrelated `feat/desktop-home` worktree and `:8090` is a dead forward). Verified-only: unit suite 1700/1700 (three clean full runs; one intermediate run under heavy parallel load showed 4 flakes that did not reproduce), `tsc --noEmit` everywhere, both Playwright configs `--list` clean, `next build` green. First cluster run should budget for small selector polish. |## 11. Post-implementation audit (2026-08-27)