Skip to content

docs: codify delivery cycle and fixture strategy#313

Merged
flyingrobots merged 1 commit intomainfrom
feat/delivery-cycle-governance
Mar 25, 2026
Merged

docs: codify delivery cycle and fixture strategy#313
flyingrobots merged 1 commit intomainfrom
feat/delivery-cycle-governance

Conversation

@flyingrobots
Copy link
Owner

@flyingrobots flyingrobots commented Mar 25, 2026

PR Title

docs: codify delivery cycle and fixture strategy

Summary

  • adopt ADR-0006 for the design-to-test delivery cycle
  • define the canonical repo fixture strategy
  • update README, roadmap, contributor docs, and agent docs to reflect the new cycle

Problem Statement

  • Git Mind had planning governance via IBM Design Thinking, but not an equally explicit delivery model connecting design acceptance criteria to executable tests and playbacks.

ADR Compliance (Required)

Relevant ADR(s)

  • ADR-0002 (Worktree Independence and Materialization Architecture)
  • ADR-0003 (Graph-Native Content, Deterministic Materialization, and Workspace Bridge)
  • None

Compliance Declaration

  • This PR is fully compliant with all checked ADRs.
  • This PR intentionally deviates from one or more checked ADRs (complete Exception Request below).

Exception Request (Required if deviating)

  • ADR clause(s) deviated from: None
  • Why deviation is necessary now: N/A
  • Risk introduced by deviation: N/A
  • Mitigation and rollback plan: N/A
  • Follow-up ADR/issue to reconcile architecture debt: N/A

Architecture Laws Checklist (Hard Gates)

Canonical Truth & Context

  • Graph remains canonical truth (no dual truth with generated files).
  • No hidden worktree coupling introduced in core/domain/materialization paths.
  • Context-sensitive behavior is explicit (--at, --observer, --trust) or deterministically defaulted.
  • Resolved context is surfaced in output metadata where applicable.

Determinism & Provenance

  • Pure query/materialization paths remain deterministic for identical inputs.
  • Mutations/materializations include provenance receipts/envelopes where required.
  • Cache keys (if used) are derived only from semantic inputs + pinned versions.

Artifact Hygiene

  • No forbidden generated artifact paths are tracked.
  • Any generated artifacts intentionally tracked are in allowlisted publish paths only.
  • Pre-commit/CI policy checks updated or confirmed valid.

Contracts & Compatibility

  • Machine-facing outputs are schema-versioned.
  • Breaking contract changes include version bump + migration notes.
  • Backward compatibility impact is documented below.

Extension/Effects Safety (if applicable)

  • Extension behavior does not bypass capability restrictions.
  • Effectful operations use explicit plan/apply semantics and emit receipts.
  • Timeouts/resource bounds are defined for new script/effect paths.

Scope Control

  • PR is single-purpose/cohesive (no unrelated refactors).
  • Any non-essential refactor is split into separate PR(s) or explicitly justified.

Backward Compatibility

  • CLI/API contract changes: None
  • Data model/storage changes: None
  • Migration required?: No
  • User-facing behavior changes: Documentation and contributor/agent workflow expectations are updated to reflect the canonical delivery cycle.

Test Plan (Required)

Unit

  • Added/updated tests for changed logic
  • Commands:
# docs-only PR; no unit tests added or updated

Integration

  • Added/updated integration tests
  • Commands:
# docs-only PR; no integration tests added or updated

Determinism

  • Determinism assertions included for relevant paths
  • Method: docs-only PR
  • Commands:
# docs-only PR; no determinism-specific test run

Contract/Schema

  • Schema validation updated/passing
  • Commands:
# docs-only PR; no schema/contract files changed

Policy Gates

  • Mechanical architecture gates pass
  • Commands:
# enforced by repo hooks and CI

Security / Trust Impact

  • Threat surface changed?: No
  • Trust policy impact: None
  • Provenance/audit impact: None
  • New failure modes introduced: None

Performance Impact

  • Hot path affected?: No
  • Expected impact (latency/memory/io): None
  • Benchmarks or profiling evidence: N/A

Observability / Debuggability

  • Errors are actionable and include context.
  • Logs/diagnostics added or updated where needed.
  • git mind status / diagnostics updated if writeback/eventing behavior changed.

Operational Notes

  • Feature flag (if any): None
  • Rollback strategy: Revert the docs/governance commit if needed
  • Operational caveats: None

Linked Issues / Milestones


Reviewer Quick Verdict Block (for maintainers)

MUST (Hard Gates)

  • PASS

SHOULD (Quality)

  • PASS

Verdict

  • APPROVE

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 25, 2026

Summary by CodeRabbit

Release Notes

  • Documentation
    • Added formal delivery cycle documentation establishing a design-to-test workflow with explicit acceptance criteria and failing tests before implementation
    • Introduced ADR-0006 defining standardized delivery process from design through testing, implementation, and post-merge backlog capture
    • Added repository fixture strategy guide for consistent and reusable test setup practices
    • Updated contributor guidelines and operational procedures to reflect new testing and validation requirements

Walkthrough

This PR codifies Git Mind's delivery cycle and repository fixture testing strategy through cross-referenced governance documentation. It establishes a design-to-test workflow requiring acceptance criteria translation into failing tests before implementation, canonical repo fixture usage for repository-shaped testing, and retrospective/README updates before PR landing. Updates span agent operational orders, contributor guidance, canonical planning docs, and new ADR-0006 formalization.

Changes

Cohort / File(s) Summary
Agent Operational Orders
AGENTS.md, CLAUDE.md
Added cross-references to delivery governance and repo fixture strategy; inserted mandatory test-translation and shared-fixture steps into "DO THE JOB" sequences; modified "FINISH THE JOB" to include playback/retrospective and optional README updates before commit/SITREP.
Contributor Workflow Guidance
CONTRIBUTING.md, ROADMAP.md
Introduced "Delivery Cycle" and "Execution Cycle" sections detailing design-to-test workflow; expanded "Testing doctrine" with coverage expectations (golden paths, edge cases, failure modes, fuzz/stress); updated checklists to require design artifacts and failing tests before implementation; added references to repo fixture strategy doc.
Canonical Planning & Reference Docs
README.md, docs/README.md, docs/design/git-mind.md
Added references to ADR-0006 and repo fixture strategy in "Canonical planning sources" and "Canonical docs" sections; updated "Contributor Rule" with sequential acceptance-criteria-to-tests and fixture steps; routed execution-cycle governance to ADR-0006.
ADR Formalization
docs/adr/ADR-0006.md, docs/adr/README.md
Created new ADR-0006 establishing formal delivery process: design → acceptance criteria → failing tests (using canonical fixtures) → implementation to green → playback/retrospective → README updates → PR merge with post-merge backlog capture; indexed new ADR in docs/adr/README.md.
Design & Fixture Documentation
docs/design/h1-semantic-bootstrap.md, docs/design/repo-fixture-strategy.md
Added "Execution Note" to Hill 1 spec requiring acceptance-criteria-to-tests translation and canonical fixture usage; created comprehensive repo-fixture-strategy document defining fluent builder model, base repos, scenario overlays, tarball vs. programmatic construction rules, canonical fixture scenarios, and migration guidance for ad hoc temp-repo conversions.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

  • docs: adopt IBM Design Thinking governance #302: Both PRs modify repository governance and procedural surfaces (AGENTS.md, CONTRIBUTING.md, README.md, ROADMAP.md, docs/README.md, docs/design/git-mind.md) by inserting mandatory workflow steps into agent/contributor sequences; ADR-0005 adds IBM Design Thinking framing while ADR-0006 adds design→failing-tests and repo-fixture rules, creating overlapping governance updates across the same documentation layer.

Poem

Design flows to tests that fail and lead the way,
Fixtures shared, no ad hoc repos astray,
Playback, README truth, the cycle made clear—
Governance codified, no more frontier. 🎯

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed Title accurately summarizes the main change: introducing ADR-0006 delivery cycle and repo fixture strategy documentation.
Description check ✅ Passed Description fully satisfies template requirements with complete sections, clear rationale, and proper ADR compliance declarations.
Linked Issues check ✅ Passed All objectives from #309 are addressed: ADR-0006 establishes delivery cycle governance, tests-as-spec is codified, fixture strategy is defined, and all canonical docs are updated.
Out of Scope Changes check ✅ Passed All changes are strictly within scope: every file modified supports the delivery cycle and fixture strategy governance objectives from #309.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/delivery-cycle-governance

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@flyingrobots flyingrobots merged commit fc0ef94 into main Mar 25, 2026
7 of 9 checks passed
@flyingrobots flyingrobots deleted the feat/delivery-cycle-governance branch March 25, 2026 15:00
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

♻️ Duplicate comments (1)
AGENTS.md (1)

70-75: ⚠️ Potential issue | 🟠 Major

DO THE JOB sequence has same fixture dependency as CLAUDE.md.

Line 71 mandates "shared repo fixtures (base repos + overlays)" but current test suite still uses ad hoc patterns (see test/views.test.js:16-17, test/content.test.js:11-17).

Fixture strategy doc's Migration Guidance (lines 177-179) confirms the builder/helpers must be built first. This operational order becomes executable only after Hill 1 delivers the fixture substrate.

The same verification script applies here to confirm fixture infrastructure gap:

#!/bin/bash
# Search for fixture builder implementation or base repo helpers

echo "=== Searching for repo fixture builder/helper implementations ==="
rg -n -C3 'repoFixture|createRepoFixture|RepoBuilder' --type=js

echo ""
echo "=== Searching for base repo definitions ==="
rg -n -C3 'minimalDocsAndCodeBase|withAdrOverlay|withIssueRefOverlay' --type=js

echo ""
echo "=== Count of test files still using mkdtemp pattern ==="
rg -l 'mkdtemp.*git-?mind-test' test/ --type=js | wc -l
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@AGENTS.md` around lines 70 - 75, Tests still rely on ad-hoc mkdtemp patterns
instead of the shared fixture substrate mandated by AGENTS.md; locate usages
like mkdtemp/give-temp-repo patterns in test/views.test.js and
test/content.test.js and replace them by wiring in the centralized fixture
builders (search for symbols repoFixture, createRepoFixture, RepoBuilder) and
base repo definitions (minimalDocsAndCodeBase, withAdrOverlay,
withIssueRefOverlay); implement or import the missing fixture builder helper(s)
per the Migration Guidance and update tests to call the shared
createRepoFixture/repoFixture helpers rather than creating repos inline (also
remove mkdtemp 'git-mind-test' usages).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@CLAUDE.md`:
- Around line 70-75: The CLAUDE.md mandate to "Prefer shared repo fixtures (base
repos + overlays)" is unexecutable because the fixture builders (repoFixture,
createRepoFixture, RepoBuilder) don't exist; implement a minimal fixture
infrastructure before enforcing this rule: add a RepoBuilder class with methods
to create base repos and apply overlays, expose helper functions
createRepoFixture and repoFixture that wrap mkdtemp/git init setup and return a
consistent fixture API (create, applyOverlay, cleanup), and update Migration
Guidance step 1 to reference these symbols so tests can switch from ad-hoc
mkdtemp + git init to the new fixtures reliably.

In `@CONTRIBUTING.md`:
- Around line 74-77: Add an explicit checklist item requiring contributors to
create a feature branch with the documented naming convention by inserting a
step such as "Create a feature branch using `git checkout -b feat/<topic>`
before writing any code" into the existing workflow list (near the steps that
start "For substantial work..." and "Add or update failing tests...") so the
`feat/<topic>` branch convention is enforced; ensure the wording matches the
repository convention and appears before "Make your changes" or "Run the tests:
`npm test`".

In `@docs/adr/README.md`:
- Around line 126-140: The markdown headings in this file (e.g. "##
[ADR-0006](./ADR-0006.md)", "### What it establishes", "### Why it matters") are
missing required blank lines before and/or after, triggering MD022; add a single
blank line immediately before each heading and ensure there is a blank line
after each heading line (and before the following paragraph or list) so each
heading is separated from surrounding content to satisfy the linter.

---

Duplicate comments:
In `@AGENTS.md`:
- Around line 70-75: Tests still rely on ad-hoc mkdtemp patterns instead of the
shared fixture substrate mandated by AGENTS.md; locate usages like
mkdtemp/give-temp-repo patterns in test/views.test.js and test/content.test.js
and replace them by wiring in the centralized fixture builders (search for
symbols repoFixture, createRepoFixture, RepoBuilder) and base repo definitions
(minimalDocsAndCodeBase, withAdrOverlay, withIssueRefOverlay); implement or
import the missing fixture builder helper(s) per the Migration Guidance and
update tests to call the shared createRepoFixture/repoFixture helpers rather
than creating repos inline (also remove mkdtemp 'git-mind-test' usages).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 05b1aaef-0718-4d75-95d2-ba9f1d907b2a

📥 Commits

Reviewing files that changed from the base of the PR and between 8bc192e and 55be077.

📒 Files selected for processing (11)
  • AGENTS.md
  • CLAUDE.md
  • CONTRIBUTING.md
  • README.md
  • ROADMAP.md
  • docs/README.md
  • docs/adr/ADR-0006.md
  • docs/adr/README.md
  • docs/design/git-mind.md
  • docs/design/h1-semantic-bootstrap.md
  • docs/design/repo-fixture-strategy.md

Comment on lines +70 to +75
2. Translate design acceptance criteria into failing tests before implementation when behavior is changing substantially
3. Prefer shared repo fixtures (base repos + overlays) where repository history or artifact shape matters
4. Drop micro-commits as you complete steps — always use conventional commit format
5. Drop a SITREP if you hit a snag or need input
6. Drop a DEVLOG for ideas, observations, or anything you want to remember
7. Use your memory banks freely
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for fixture builder implementation or base repo helpers

echo "=== Searching for repo fixture builder/helper implementations ==="
rg -n -C3 'repoFixture|createRepoFixture|RepoBuilder' --type=js

echo ""
echo "=== Searching for base repo definitions ==="
rg -n -C3 'minimalDocsAndCodeBase|withAdrOverlay|withIssueRefOverlay' --type=js

echo ""
echo "=== Count of test files still using mkdtemp pattern ==="
rg -l 'mkdtemp.*git-?mind-test' test/ --type=js | wc -l

Repository: flyingrobots/git-mind

Length of output: 235


Fixture mandate isn't executable—required infrastructure doesn't exist.

Line 71 mandates "shared repo fixtures (base repos + overlays)" but the codebase has zero fixture builders (repoFixture, createRepoFixture, RepoBuilder all absent). Meanwhile, 15 test files still lean on ad hoc mkdtemp + git init anti-patterns. This creates an unresolvable bootstrapping problem: you're asking the team to follow a practice that has no substrate yet. Build the fixture infrastructure (step 1 of Migration Guidance, lines 177–179) and ship it before making this an operational mandate.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@CLAUDE.md` around lines 70 - 75, The CLAUDE.md mandate to "Prefer shared repo
fixtures (base repos + overlays)" is unexecutable because the fixture builders
(repoFixture, createRepoFixture, RepoBuilder) don't exist; implement a minimal
fixture infrastructure before enforcing this rule: add a RepoBuilder class with
methods to create base repos and apply overlays, expose helper functions
createRepoFixture and repoFixture that wrap mkdtemp/git init setup and return a
consistent fixture API (create, applyOverlay, cleanup), and update Migration
Guidance step 1 to reference these symbols so tests can switch from ad-hoc
mkdtemp + git init to the new fixtures reliably.

Comment on lines +74 to +77
2. For substantial work, start from a design artifact and acceptance criteria
3. Add or update failing tests before implementation when behavior is changing
4. Make your changes
5. Run the tests: `npm test`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

Enforce the feature-branch naming rule in the updated workflow checklist.

This section now formalizes delivery workflow, but it still doesn’t require the documented feat/<topic> branch convention. Please make that explicit here to avoid governance drift between contributor docs and agent instructions.

Based on learnings, “Create a feature branch using git checkout -b feat/<topic> before writing any code.”

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@CONTRIBUTING.md` around lines 74 - 77, Add an explicit checklist item
requiring contributors to create a feature branch with the documented naming
convention by inserting a step such as "Create a feature branch using `git
checkout -b feat/<topic>` before writing any code" into the existing workflow
list (near the steps that start "For substantial work..." and "Add or update
failing tests...") so the `feat/<topic>` branch convention is enforced; ensure
the wording matches the repository convention and appears before "Make your
changes" or "Run the tests: `npm test`".

Comment on lines +126 to +140
## [ADR-0006](./ADR-0006.md) — Design Acceptance Becomes Tests, Canonical Repo Fixtures Power Delivery
**Status:** Accepted
**Date:** 2026-03-25

### What it establishes
- substantial work follows a design-to-test delivery cycle
- design acceptance criteria should be translated into failing tests
- tests are expected to cover more than golden paths when risk justifies it
- canonical repository-shaped fixtures should replace growing ad hoc temp-repo boilerplate
- playback, README reality updates, and post-merge backlog capture are part of cycle close

### Why it matters
Turns IBM Design Thinking from planning discipline into an executable delivery model, and gives Git Mind a realistic test substrate for repository-shaped behavior.

---
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Fix missing blank lines around headings.

Static analysis correctly flagged MD022 violations. Headings require blank lines before and after for consistent markdown rendering.

📐 Proposed formatting fix
 ---
 
+
 ## [ADR-0006](./ADR-0006.md) — Design Acceptance Becomes Tests, Canonical Repo Fixtures Power Delivery
 **Status:** Accepted
 **Date:** 2026-03-25
 
+
 ### What it establishes
 - substantial work follows a design-to-test delivery cycle
 - design acceptance criteria should be translated into failing tests
 - tests are expected to cover more than golden paths when risk justifies it
 - canonical repository-shaped fixtures should replace growing ad hoc temp-repo boilerplate
 - playback, README reality updates, and post-merge backlog capture are part of cycle close
 
+
 ### Why it matters
 Turns IBM Design Thinking from planning discipline into an executable delivery model, and gives Git Mind a realistic test substrate for repository-shaped behavior.
 
 ---
+
🧰 Tools
🪛 markdownlint-cli2 (0.21.0)

[warning] 126-126: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 130-130: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


[warning] 137-137: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/adr/README.md` around lines 126 - 140, The markdown headings in this
file (e.g. "## [ADR-0006](./ADR-0006.md)", "### What it establishes", "### Why
it matters") are missing required blank lines before and/or after, triggering
MD022; add a single blank line immediately before each heading and ensure there
is a blank line after each heading line (and before the following paragraph or
list) so each heading is separated from surrounding content to satisfy the
linter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

governance: codify delivery cycle and repo fixture testing strategy

1 participant