Skip to content

Validate + test

Two verbs share the quality-gate surface (RFC §9.4):

  • dockyard validate — fast, build-blocker check (manifest, schemas, tool↔UI mappings, App MIME, spec compliance, four-state UI rule, stale-codegen drift).
  • dockyard test — the full contract + compliance + capability gate.

Both exit non-zero on a regression; warnings report inline.

dockyard validate

bash
dockyard validate            # in the project directory
dockyard validate --dir path/to/project

The checks:

CategoryWhat it catches
manifestmalformed dockyard.app.yaml, missing required fields
schemasthe generated JSON Schema is not valid against draft-2020-12
tool↔UI mappingsa tool's ui: <id> does not match any apps[].id
MIMEan App's resource MIME is not text/html;profile=mcp-app
spec compliancethe Apps/Tasks shapes deviate from the vendored specs
four-state UI rulea fixture is missing for a required UI state (§20)
stale-codegenthe generated *.gen.* files no longer match the Go source
CrossCheckthe generated TS would differ from on-disk if regenerated (D-113)

dockyard build runs validate first; a blocker fails the build.

dockyard test

bash
dockyard test
dockyard test --skip-go-test

Categories:

CategoryWhat it runs
go-testgo test ./... in the project
contractgenerated artifacts match the Go contracts
goldenfixtures / goldens are coherent
spec-complianceconformance against the vendored MCP specs
capabilitythe project degrades gracefully across host capability sets

Reading the report

Both verbs print:

text
  blocker: tool "create_chart" references app "wigets" — no such app id
  warning: tool "summarise" has no fixture for the "permission" state
  validate: 1 blocker, 1 warning

A blocker exits non-zero; warnings don't change the exit code.

CI shape

yaml
- run: dockyard validate
- run: dockyard test

Both are idempotent and produce deterministic output. Pin them into your CI workflow.

See also

Apache-2.0 licensed — see LICENSE.