Audit bf-gcotl found every dashboard read of the blob identity fields (personName/assignedColor/identityResolved + snake_case aliases person_name/assigned_color/person_label/person_color) is already guarded at the call site — zero unguarded reads (full verdict table recorded on bf-2gmx). The only two spots that dereference an identity NAME (.length/.charCodeAt) without a local guard were the reusable color helpers, both safe today but hardened defensively so the guard contract holds for future callers: - ambient_renderer.js getPersonColor: if (!personName) return '#6b7280' - ble-panel.js getColorForPerson: if (!personName) return '#888888' Type contract unchanged and verified: tsc --noEmit -p dashboard/tsconfig.json passes; spaxel.d.ts still declares personName?/assignedColor?/identityResolved? optional with deprecated aliases; blob-identity.check.ts asserts the identityResolved true/false/undefined tri-state. |
||
|---|---|---|
| .. | ||
| css | ||
| js | ||
| static | ||
| test-results | ||
| tests | ||
| types | ||
| ambient.html | ||
| fleet.html | ||
| help_articles.json | ||
| index.html | ||
| integrations.html | ||
| jest.config.js | ||
| live.html | ||
| package-lock.json | ||
| package.json | ||
| playwright.config.js | ||
| README.md | ||
| setup.html | ||
| simple.html | ||
| simulator.html | ||
| test-transformcontrols.html | ||
| tsconfig.json | ||
Spaxel Dashboard
Running Tests
Unit Tests (Jest)
npm test
Accessibility Tests (axe-core + Playwright)
# First-time setup: install browsers
npx playwright install --with-deps chromium
# Run accessibility gate
npm run test:a11y
The accessibility test loads each dashboard page (index, live, fleet, setup, integrations) via a local static server and asserts zero WCAG 2A/2AA violations using @axe-core/playwright. CI fails the build if any violation is introduced.
CI Integration (Argo Workflows)
Add the following step to the spaxel-build WorkflowTemplate before the container build:
- name: a11y-gate
container:
image: node:20-bookworm-slim
command: [sh, -c]
args:
- |
cd dashboard
npm ci
npx playwright install --with-deps chromium
npm run test:a11y
resources:
limits:
memory: 512Mi
cpu: "1"