Skip to main content

Checks And Validation

This page catalogs every local check, test, lint, and build-validation command you can run before committing. It also maps them to the CI gates they mirror.

Run the Quick Pre-Commit commands before every push. Use the area-specific commands when you touch a particular subsystem.


Quick Pre-Commit (~60s total)

These four commands mirror what CI runs on every PR. If they all pass, your change is clean.

# 1. Rust runtime tests (~30s)
cargo test --manifest-path ./runtime/Cargo.toml

# 2. Renderer TypeScript typecheck (~5s)
npm --prefix ./Frontend/HolonClient run typecheck

# 3. Renderer ESLint (~3s)
npm --prefix ./Frontend/HolonClient run lint

# 4. Renderer unit/component tests (~10s)
npm --prefix ./Frontend/HolonClient run test -- --run

Command Catalog

HolonClient — Renderer (React / Vite)

CommandWhat It RunsCategoryIn CI?
npm --prefix ./Frontend/HolonClient run typechecktsc --noEmit — strict TypeScript type-checktypecheck✅ ci.yml
npm --prefix ./Frontend/HolonClient run linteslint . — flat config (TS parser, react-hooks, react-refresh, Tauri import boundary)lint✅ ci.yml
npm --prefix ./Frontend/HolonClient run lint:host-boundarydepcruise — no direct @tauri-apps imports outside Infrastructure/host/architecture❌ manual only
npm --prefix ./Frontend/HolonClient run test -- --runvitest — jsdom, globals, React pluginunit test✅ ci.yml
npm --prefix ./Frontend/HolonClient run check:chunksBundle chunk size budget enforcementbuild❌ manual only
npm --prefix ./Frontend/HolonClient run check:workflow-contractValidates workflow-contract Zod schema is importableschema❌ manual only
npm --prefix ./Frontend/HolonClient run proof:elegy-contract-consumptionValidates Elegy contract schema compatibility (requires --contracts <dir>)contract❌ triggered via bootstrap
npm --prefix ./Frontend/HolonClient run e2eplaywright test — desktop Chrome E2E, base URL localhost:4173e2e❌ manual only
npm --prefix ./Frontend/HolonClient run e2e:summarySummarizes Playwright JSON resultsreporting❌ manual only
npm --prefix ./Frontend/HolonClient run buildvite build — production renderer bundlebuild❌ (staged in packaging step)

Config files:

  • Frontend/HolonClient/vitest.config.ts — jsdom environment, globals, React plugin, path aliases
  • Frontend/HolonClient/playwright.config.ts — desktop Chrome, 60s timeout, 2 CI retries, HTML + JSON reporters
  • Frontend/HolonClient/eslint.config.js — ESLint 9 flat config, TypeScript parser, architectural import boundary rule
  • Frontend/HolonClient/tsconfig.json — strict mode, ESNext modules, noEmit, path aliases

HolonDesktop — Tauri Shell

CommandWhat It RunsCategoryIn CI?
npm --prefix ./Frontend/HolonDesktop run testNode --test runner → desktopHostLifecycle/*.test.js (2 files)unit test✅ ci.yml
npm --prefix ./Frontend/HolonDesktop run test:real-desktopPlaywright real-desktop E2E — launches actual Tauri window, specs/startup.real-desktop.spec.tse2e❌ manual only
npm --prefix ./Frontend/HolonDesktop run verify:workspace-parityValidates Tauri command registration parity across main.rs handler macro, permissions allow-list, and capability bindingsarchitecture❌ manual only
npm --prefix ./Frontend/HolonDesktop run verify:packaging-readinessAudits tauri.conf.json, icons, renderer dist, Cargo.toml features, writes readiness reportbuild✅ ci.yml
npm --prefix ./Frontend/HolonDesktop run package:stage:win-x64Builds HolonClient renderer + validates staged packaging inputsbuild✅ ci.yml

Note: HolonDesktop does not have its own lint or typecheck scripts. TypeScript config in tests/real-desktop/tsconfig.json covers only test files. Desktop script validation relies on CI's build step.

Config files:

  • Frontend/HolonDesktop/tests/real-desktop/playwright.real-desktop.config.ts — 180s timeout, single worker, retain-on-failure video/trace

Rust Runtime (runtime/)

CommandWhat It RunsCategoryIn CI?
cargo build --manifest-path ./runtime/Cargo.tomlBuilds all 13 workspace cratesbuild✅ (implicit in test)
cargo test --manifest-path ./runtime/Cargo.tomlAll Rust unit + integration tests across 13 cratesunit test✅ ci.yml
cargo test -p <crate>Narrow to one specific crateunit test❌ (dev tool)

Workspace crates: holon-adapter-core, holon-api-adapter, holon-planning-adapter, holon-protocol, holon-store, holon-runtime-core, holon-transport, holon-runtime-client, holon-cli, holon-structured-output, holon-workflow, holon-crystallization, holon-executor

Known gaps: No cargo clippy or cargo fmt --check in CI. No cargo audit/cargo deny for dependency vulnerability scanning. No rust-toolchain.toml for local dev consistency.


Docs (docs/system/, docs/website/)

CommandWhat It RunsCategoryIn CI?
./scripts/check-doc-authoring.ps1Validates YAML frontmatter on all docs/system/**/*.md — 8 required fields, allowed values for status/doc_kind, sidebar resolution, manifest path existencedocs✅ ci.yml
./scripts/check-doc-links.ps1Resolves all internal markdown links under docs/system/**; forbids links into docs/todo/docs✅ ci.yml
./scripts/check-no-committed-env.ps1Guards against committed .env / .env.production under Frontend/HolonClientsecurity❌ manual (release-prep)
npm run docs:builddocusaurus build — production docs website buildbuild✅ ci.yml

Version & Release

CommandWhat It RunsCategoryIn CI?
./scripts/verify-version.ps1Validates version consistency across 15+ files (Cargo.toml, package.json, package-lock.json, tauri.conf.json, changelog.md, Cargo.lock)release✅ ci.yml, release.yml
./scripts/verify-version.ps1 -Tag vX.Y.ZSame as above, but enforces a specific expected versionrelease✅ release.yml
./scripts/export-release-notes.ps1Extracts changelog entry for a version to a filerelease✅ release.yml
npm --prefix ./Frontend/HolonDesktop run verify:packaging-readinessAudits tauri.conf.json, icons, renderer dist, Cargo.toml featuresrelease✅ ci.yml

Elegy Bridge

CommandWhat It RunsCategoryIn CI?
./scripts/validate-elegy-bridge-freeze.ps1Scans repo for legacy NuGet/GitHub-Packages bridge references (zero-tolerance)contract✅ bridge-freeze, bootstrap-proof
./scripts/bootstrap-elegy-distribution.ps1 -ForceDownloads + installs + validates pinned Elegy release, proves contract consumptioncontract✅ bootstrap-proof
./scripts/prove-holon-consumption.ps1Validates install receipt + Elegy contract schema compatibility via tsx proofcontract❌ (called by bootstrap)

Config: scripts/elegy-bootstrap.config.json — pins Elegy tag (v1.3.2), CLI/wrapper surfaces, proof contract entries.


WS5 Scripts (Milestone Tooling)

CommandWhat It RunsCategoryIn CI?
npm --prefix ./Frontend/HolonClient run ws5:auth-nav:defect-gateRuns targeted vitest suites for auth-navigation regressions, writes artifact JSONregression gate❌ manual only
npm --prefix ./Frontend/HolonClient run ws5:host-matrix:artifactGenerates host matrix documentation artifact (JSON + Markdown)artifact❌ manual only
npm --prefix ./Frontend/HolonClient run ws5:rolloutToggles runtime config env vars for WS5 rollout stagesconfig❌ manual only

CI Workflows (GitHub Actions)

CI (ci.yml) — Runs on PR and push (non-tags)

Four parallel jobs, ~20-30 min:

JobRunnerSteps
rust-runtimeubuntuCheckout → Rust 1.83.0 → Restore cache → cargo test
holon-clientubuntuCheckout → Node 20.19.0 → npm cilinttypechecktest -- --run
holon-desktopwindowsCheckout → Node 20.19.0 → npm cipackage:stage:win-x64testverify:packaging-readiness
docs-and-versionubuntuCheckout → Node 20.19.0 → npm civerify-version.ps1check-doc-authoring.ps1check-doc-links.ps1docs:build

Release (release.yml) — Runs on v* tag push

Two sequential jobs:

  1. release-windows (120 min): Checkout → verify version → stage packaging → build desktop installer (signed) → build CLI → smoke test both → upload assets → publish release
  2. post-publish-verify (ubuntu): Download published assets → verify manifest → verify checksums

Preview Release (preview-release.yml) — Runs on push to master

Builds unsigned preview installer, publishes to preview GitHub release.

Elegy Bridge Freeze (elegy-bridge-freeze.yml)

Runs on every PR and push to main/master. Fast (~1 min): validates no legacy Elegy NuGet/GitHub-Packages bridge references exist.

Elegy Bootstrap Proof (elegy-bootstrap-proof.yml)

Path-filtered: triggers only when Elegy-related files change. Validates bridge freeze, then bootstraps Holon from pinned Elegy release.


VS Code Tasks

Configured in .vscode/tasks.json:

TaskDescription
playwright-e2eRun Playwright E2E tests from HolonClient
checkpoint: holon-client testsRun focused vitest suite (DesktopHomePage, WorkspaceShellLayout, workspaceRouteCanonicalization)
checkpoint: holon-client typecheckRun HolonClient TypeScript typecheck
checkpoint: holon-client lintRun HolonClient ESLint

Known Gaps

GapImpactNotes
No pre-commit hooksCan commit broken code; everything relies on CIConsider adding lefthook or husky
No cargo clippy in CIRust lint regressions undetectedAdd to ci.yml rust-runtime job
No cargo fmt --checkInconsistent Rust formattingAdd with rustfmt.toml
No cargo audit/cargo denyUnscanned Rust dependency vulnsAdd scheduled workflow
No rust-toolchain.tomlLocal dev may use different Rust version than CIAdd file pinning 1.83.0
HolonDesktop: no lint/typecheckType errors in desktop scripts undetectedNeeds own tsconfig.json + eslint config
HolonDesktop: minimal test coverageOnly 2 Node test files cover the shellNeeds expansion
No CodeQL / security scanningNo automated vulnerability detectionAdd CodeQL workflow
Real-desktop E2E not in CIDesktop shell E2E only testable locallyCould run on self-hosted Windows runner
No unified local "run all" scriptFragmented pre-commit experienceConsider scripts/pre-commit.ps1 orchestrator
Dependabot: security-only updatesNon-security dependency drift goes unnoticedConsider expanding update types
Dependabot: missing ecosystemsNo cargo, github-actions, docs/website coverageAdd missing ecosystem entries

Script Quality Baseline

All scripts/ validation scripts follow these conventions:

  • Set-StrictMode -Version Latest — strict PowerShell parsing
  • $ErrorActionPreference = 'Stop' — halt on any cmdlet failure
  • Explicit exit codes (0 = success, 1 = failure, 2 = prerequisite missing)
  • No hardcoded user paths; everything resolved relative to $PSScriptRoot
  • try/finally hygiene for temp directory and environment variable cleanup

Script health was audited on 2026-06-09. Removed: prove-saastools-consumption.ps1 (duplicate), check-canonical-docs-sync.ps1 (stale post-migration guard). Removed stale .vscode/tasks.json entries for deleted .NET plugin tests and scratch tmp: tasks.


Adding A New Check

When adding a new validation command or script:

  1. Add the npm/cargo script to the relevant package.json or Cargo.toml
  2. Wire it into CI in .github/workflows/ci.yml if it should gate every PR
  3. Add it to this document under the appropriate category
  4. Add it to the sidebar if it warrants a dedicated guide page
  5. Run ./scripts/check-doc-authoring.ps1 if you add/changed any docs metadata
  6. Run ./scripts/check-doc-links.ps1 if you added cross-references