Skip to content

T-LIYW-test-fixture-id-drift

Status: closed/done · Impact: medium · Complexity: small

The task schema (schema_version 5, plugin/lib/model/entities/task/schema.json) now lists id (pattern ^T-[0-9A-Z]{4}$) as a required property. Several test files still build task frontmatter — inline strings and fixture files — from before id was required, so those fixtures fail schema validation with 'id' is a required property. This is fixture drift, not a behavior bug: the production validator, skills, and schema are correct; only the test inputs are stale. Repairing them restores a clean test baseline so the milestone’s test gates run green.

LocationRole today
plugin/validators/tests/task_autonomy_enum.test.tsBuilds task frontmatter without id; autonomy-enum cases fail schema validation.
plugin/skills/task-auto-define/tests/task_auto_define.test.tsSeeds a task fixture lacking id; the auto-define readiness case fails.
plugin/skills/task-define/tests/task_define.test.tsInline frontmatter fixtures omit id; behavioural-layer cases report a spurious <root> failing pointer.
plugin/skills/task-ensure-ready/tests/ensure_ready.test.tsSeveral fixtures omit id; readiness cases fail on the schema gate.
plugin/skills/task-close-out/tests/prs_verify.test.tsTask fixtures used by the prs verify/append cases lack id.

Every test fixture / inline task-frontmatter input across those five files carries a schema-valid, obviously-synthetic id (e.g. T-0000, T-TST1 matching ^T-[0-9A-Z]{4}$, plus any other field the schema now requires but the fixture omits). All five files run fully green. No production code, schema, skill .ts logic, or SKILL.md is touched. The full-suite failure count drops by exactly the fixture-drift amount these five files contribute.

  1. Reproduce: bun test to capture the baseline, then per-file to isolate each failing set and confirm the error is 'id' is a required property (or other newly-required-but-missing schema fields), not behavior drift.
  2. For each file, add a synthetic schema-valid id to every task fixture / inline frontmatter block that lacks one, keeping ids obviously fake.
  3. Re-run each file to green, then the full suite to confirm the count drop.
  4. Keep bunx tsc --noEmit green.
LocationKindChange
plugin/validators/tests/task_autonomy_enum.test.tsmodifyAdd synthetic id to task frontmatter fixtures.
plugin/skills/task-auto-define/tests/task_auto_define.test.tsmodifyAdd synthetic id to the seeded task fixture.
plugin/skills/task-define/tests/task_define.test.tsmodifyAdd synthetic id to inline frontmatter fixtures.
plugin/skills/task-ensure-ready/tests/ensure_ready.test.tsmodifyAdd synthetic id to the fixtures missing it.
plugin/skills/task-close-out/tests/prs_verify.test.tsmodifyAdd synthetic id to the task fixtures.
  • AC-1: bun test plugin/validators/tests/task_autonomy_enum.test.ts passes.
  • AC-2: The four skill test files (task-auto-define, task-define, task-ensure-ready/ensure_ready, task-close-out/prs_verify) pass.
  • AC-3: The full-suite failure count drops by exactly the fixture-drift amount these five files contribute, with no new failures introduced.
  • AC-4: bunx tsc --noEmit stays green.
  • Production code, the task schema, skill .ts logic, and SKILL.md files.
  • The tests/parity/validators.golden.test.ts golden-suite failures, which are driven by live docs/planning/ entity renames/migration owned by another agent — not by the five fixture sets named here.
  • none
  • Surfaced while preparing a clean test baseline for the active milestone: on clean main bun test reports a block of 'id' is a required property failures concentrated in these five test files after the task schema made id required at schema_version 5.

← Back to Tasks