Repository navigation
test(cli): add Quillhaven systems conformance corpus with TypeScript runner - #718
Merged
Merged
Conversation
…t runner fixtures/systems-conformance/quillhaven/ is the systems half of the round-2 test estate: six repositories (quillhaven-common, larkspur-pay, corvid-wayfinder, quillhaven-rates, quillhaven-parcels, quillhaven-ledger) holding the design's eleven files, each with its own config, committed dependency snapshots and lock. Parcels and Ledger import each other's contract package only. The TypeScript runner (cli/test/systems-conformance.test.ts) checks four arms: every publish.json selection is the snapshot its consumers committed and the lock entry that pins it, and each contract package publishes from its own file alone; each repository loads from its own root to expected/<repo>.canonical.json; every package is byte-identical from every root that loads it (expected/packages/); and 21 cases.json changes raise their loader code, or, when the Tidewell stub gives way to Tidewell's own package, leave the model byte-identical. Two design files changed to load on main: two REST paths keyed by a value object now take the key as input, and the weekly settlement export names its day. Adds the CONFORMANCE.md row and section and moves the corpus counts to 50.
The design expects a stub left beside Tidewell's own package to be refused with ERR_DEPENDENCY_PACKAGE_NOT_OWNED. Main merges same-named dependency nodes instead, so the case stays in cases.json marked knownGap, and runners skip it and report the reason until the ownership rule is decided.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What Changed
fixtures/systems-conformance/quillhaven/: six repositories (11 metadata files) with their own.metaobjects/config.json, committed dependency snapshots and locks, pluspublish.json,expected/<repo>.canonical.json,expected/packages/*.json, andcases.json(22 single-change cases, one markedknownGap). A corpus README documents the format.server/typescript/packages/cli/test/systems-conformance.test.ts, which runs four arms: publish (each published contract package is byte-identical to the consumer-committed snapshot and lock entry, and loads with nothing beside it), reader (each repository loads from its own root with its own dependencies), packages (each package is byte-identical across every root that loads it), and cases (each change raises the expected loader code or leaves the canonical form unchanged). The known-gap case is skipped and reported.docs/CONFORMANCE.md(TypeScript passing; Java, C#, Python and Rust rows marked planned), and updates the corpus count from 49 to 50 inAGENTS.mdandexamples/showcase/site-payload.json. Adds a changelog fragment noting corpus-only change.No product behavior, vocabulary, or generator output changed.
Where this differs from the round-2 design
The corpus follows main's vocabulary wherever the design and main disagree:
PaymentsApi.getCharge(/v2/charges/{chargeId}) andShipmentApi.trackShipment(/shipments/{trackingNumber}) had a key in the path. On main a path placeholder must be the primary key of the operation's target entity, and a contract package declares values, not entities, so both failed withERR_BINDING_PATH_MISMATCH. Each now takes its key as an input value (ChargeLookup,TrackingLookup) atPOST /v2/charges/lookupandGET /shipments/track.SettlementFeed.weeklySettlement @availableByisMon 06:00, not06:00: main requires a weekly@availableByto name its day (ERR_BAD_ATTR_VALUE). The design's spelling is kept as the casea-weekly-export-without-a-day.ERR_DEPENDENCY_PACKAGE_NOT_OWNED. On main a local node with the same name as a dependency node merges with it, and the refusal covers only new nodes; the load fails today withERR_MERGE_CONFLICTonly because the stub spellsowner: Tidewellwhere the published form hastidewell::Tidewell. The casethe-stub-refuses-a-publisher-beside-itkeeps the design's expectation, markedknownGap, and runners skip it with that reason. Decision: the ownership rule is adopted per the design and ships as its own follow-up in every port, which un-skips this case.Not covered here: the estate half (delivery pack, TypeScript only), and the whole-model rules (
ERR_API_NOT_CARRIED,ERR_API_NO_PROVIDER, the extract chain), which joincases.jsonas"stage": "verify"with the rule hook (H2).Validation
Risk Assessment
✅ Low: Corpus-only change: 6 repos with 11 metadata files, expected snapshots, 22 cases (1 documented knownGap skip) and one TS runner, all matching the stated intent; counts in docs, changelog and AGENTS.md agree with the files, and no product code or vocabulary changed.
Testing
Drove the three intent scenarios through the real loader using the committed Quillhaven corpus and its TypeScript runner: each repository loads from its own root to expected canonical output, every package is byte-identical from every root that loads it, contract packages publish standalone, and 21 cases raise their loader codes or keep the model byte-identical when the stub gives way. All executed runs pass (31 pass, 1 skip, 0 fail on the full file). Broad regression came from the configured test command scripts/ci-local.sh --affected --strict-toolchains with its passing outcome at this commit. No evidence files were written; the output is test-runner text, not a reviewer-visible product surface. The skipped case is a known gap recorded in cases.json, not a failure.
bun test test/systems-conformance.test.tsin server/typescript/packages/cli; 'reader: <repo> loads from its own root' arms passPipeline
Updates from git push no-mistakes
✅ **Intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
fixtures/systems-conformance/quillhaven/cases.json- Case: a stub left beside Tidewell's own package should be refused with ERR_DEPENDENCY_PACKAGE_NOT_OWNED. Main merges same-named dependency nodes instead, so the case is skipped as knownGap. Needs a human decision: adopt the ownership rule (loader change) or keep the design expectation as a gap.bun test test/systems-conformance.test.tsin server/typescript/packages/cli; 'reader: <repo> loads from its own root' arms passscripts/ci-local.sh --affected --strict-toolchainsbun test test/systems-conformance.test.tsin server/typescript/packages/cli (full file: 31 pass, 1 skip, 0 fail)bun test test/systems-conformance.test.ts --test-name-pattern "stub|reader|standalone|stand alone|byte|loader|contract"(11 pass, 1 skip, 0 fail)Read systems-conformance.test.ts test structure: publish arm, reader arm per repo, packages byte-identity arm, 21 case arms, knownGap skipBaseline: scripts/ci-local.sh --affected --strict-toolchains passed at target commit (not re-run; no source changed in this turn)✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.