refactor: hard-fork GSD -> MSD (Make Software Done)

Mechanical rename produced by scripts/msd-rename.cjs: gsd/Gsd/GSD -> msd/Msd/MSD
across contents and paths, upstream package/repo coordinates -> @golem15/msd-core
and golem15com/msd-core. Deep links into upstream history, sibling upstream
packages, the GSD-2 import feature, CHANGELOG.md and .changeset/ are kept as-is.

Hand edits on top: MSD block-letter banner and logos, LICENSE copyright line,
package/plugin identity, regenerated lockfile, install-tree fixtures, derived
registries and benchmark baseline; migration checksum baseline re-locked
(MSD keeps its own install state, so no install had applied the old sums);
sort-order and regex-escaped expectations in tests adjusted.
This commit is contained in:
Jakub Zych
2026-10-06 01:47:40 +02:00
parent fe069b2a56
commit a9a7a328e6
2763 changed files with 78465 additions and 78434 deletions

View File

@@ -4,18 +4,18 @@
* Tests for `src/planning-inspect.cts` — the schema-v1 canonical planning
* snapshot (`query planning inspect` / `query planning.inspect`, #2790).
*
* Design: .gsd/phase/feat-2790-planning-inspect/40-design.md
* Test matrix: .gsd/phase/feat-2790-planning-inspect/50-test-matrix.md
* Design: .msd/phase/feat-2790-planning-inspect/40-design.md
* Test matrix: .msd/phase/feat-2790-planning-inspect/50-test-matrix.md
*
* Fixture provenance (CONTRIBUTING.md "Fixture provenance (#2371)"): every
* `.planning/` document shape written by this file's fixture builders is
* derived from the SHIPPED templates the product author wrote —
* `gsd-core/templates/requirements.md` (checkbox bullets, `## Traceability`
* table), `gsd-core/templates/phase-prompt.md` (the `<task>` XML grammar and
* `## Task N` legacy heading fallback), `gsd-core/templates/summary.md`
* `msd-core/templates/requirements.md` (checkbox bullets, `## Traceability`
* table), `msd-core/templates/phase-prompt.md` (the `<task>` XML grammar and
* `## Task N` legacy heading fallback), `msd-core/templates/summary.md`
* (`## Files Created/Modified`, `## Deviations from Plan` / `**Found
* during:**` / `**Files modified:**`), `gsd-core/templates/state.md`
* (`## Current Position`), and `gsd-core/templates/roadmap.md` (`## Phases`
* during:**` / `**Files modified:**`), `msd-core/templates/state.md`
* (`## Current Position`), and `msd-core/templates/roadmap.md` (`## Phases`
* checkbox list, `### Phase N: Name` headings) — never from
* `planning-inspect.cts`'s own parsing model. `planning.inspect` has no
* writer of its own (it is read-only), so the property-test generator in
@@ -23,7 +23,7 @@
* document-shaped from those same templates, not seeded from the module
* under test.
*
* `runGsdTools(['query', 'planning', 'inspect'], tmpDir)` is the invocation
* `runMsdTools(['query', 'planning', 'inspect'], tmpDir)` is the invocation
* shape used throughout — array form, shell-bypassed, safe for hostile
* fixture values (CONTRIBUTING "CLI and command routing").
*/
@@ -34,8 +34,8 @@ const fs = require('node:fs');
const path = require('node:path');
const fc = require('fast-check');
const { createTempProject, createTempDir, cleanup, runGsdTools, toPosixPath } = require('./helpers.cjs');
const { generateSlugInternal } = require('../gsd-core/bin/lib/core-utils.cjs');
const { createTempProject, createTempDir, cleanup, runMsdTools, toPosixPath } = require('./helpers.cjs');
const { generateSlugInternal } = require('../msd-core/bin/lib/core-utils.cjs');
// ─── Fixture helpers ──────────────────────────────────────────────────────────
@@ -120,8 +120,8 @@ function slugPhaseDirName(token, name) {
/**
* Declare one phase in STATE.md + ROADMAP.md (milestone window), matching
* `gsd-core/templates/roadmap.md`'s `### Phase N: Name` heading shape and
* `gsd-core/templates/state.md`'s frontmatter shape. The ROADMAP prose
* `msd-core/templates/roadmap.md`'s `### Phase N: Name` heading shape and
* `msd-core/templates/state.md`'s frontmatter shape. The ROADMAP prose
* (heading + checkbox bullet) carries the BARE numeric token, exactly as real
* ROADMAP.md documents do — `buildRoadmapPhaseCheckboxesField` and the
* requirement-traceability parser both capture this bare form. The returned
@@ -129,7 +129,7 @@ function slugPhaseDirName(token, name) {
* projects and `tests/planning-snapshot.test.cjs`'s own fixtures.
*/
function declarePhase(cwd, token, name, { checkedInPhaseList = false } = {}) {
writeState(cwd, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(cwd, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
const phaseListLine = checkedInPhaseList
? `- [x] **Phase ${token}: ${name}** - stub`
: `- [ ] **Phase ${token}: ${name}** - stub`;
@@ -153,7 +153,7 @@ function declarePhase(cwd, token, name, { checkedInPhaseList = false } = {}) {
/** A healthy two-phase project: both phases complete, requirements mapped. */
function buildHealthyFixture(cwd, eol = '\n') {
writeState(cwd, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0'], [], eol);
writeState(cwd, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0'], [], eol);
writeRoadmap(cwd, [
'## v1.0 Current 🚧',
'',
@@ -260,7 +260,7 @@ function sortedKeys(obj) {
}
function runInspect(tmpDir, extraArgs = []) {
return runGsdTools(['query', 'planning', 'inspect', ...extraArgs], tmpDir);
return runMsdTools(['query', 'planning', 'inspect', ...extraArgs], tmpDir);
}
function parseInspect(tmpDir, extraArgs = []) {
@@ -270,7 +270,7 @@ function parseInspect(tmpDir, extraArgs = []) {
}
function runInspectJsonError(tmpDir, extraArgs) {
const result = runGsdTools(['query', 'planning', 'inspect', ...extraArgs, '--json-errors'], tmpDir);
const result = runMsdTools(['query', 'planning', 'inspect', ...extraArgs, '--json-errors'], tmpDir);
assert.strictEqual(result.success, false, `expected failure for args: ${extraArgs.join(' ')}`);
let parsed;
try {
@@ -316,7 +316,7 @@ describe('planning inspect — schema contract', () => {
t.after(() => cleanup(tmpDir));
buildHealthyFixture(tmpDir);
const planningSnapshotLib = require('../gsd-core/bin/lib/planning-snapshot.cjs');
const planningSnapshotLib = require('../msd-core/bin/lib/planning-snapshot.cjs');
const snapshot = planningSnapshotLib.buildPlanningSnapshot(tmpDir);
// PlanningSnapshot's own key set is whatever it is (additive, churning) —
// asserted only to prove this test is exercising the real module, not a
@@ -329,12 +329,12 @@ describe('planning inspect — schema contract', () => {
test('locksSchemaVersionConstantAgainstTheExportedModule', () => {
// Loading a module's exported runtime value, not source-grepping text.
const planningInspectLib = require('../gsd-core/bin/lib/planning-inspect.cjs');
const planningInspectLib = require('../msd-core/bin/lib/planning-inspect.cjs');
assert.strictEqual(planningInspectLib.PLANNING_INSPECT_SCHEMA_VERSION, 1);
});
test('locksDiagnosticTaskStatusProvenanceAndAgreementEnums', () => {
const planningInspectLib = require('../gsd-core/bin/lib/planning-inspect.cjs');
const planningInspectLib = require('../msd-core/bin/lib/planning-inspect.cjs');
const expectedDiagnosticKeys = [
'PLANNING_ROOT_ABSENT', 'ROADMAP_UNSCOPED', 'REQUIREMENTS_ABSENT', 'REQUIREMENTS_UNREADABLE',
@@ -357,7 +357,7 @@ describe('planning inspect — schema contract', () => {
buildHealthyFixture(tmpDir);
const spaced = parseInspect(tmpDir);
const dottedResult = runGsdTools(['query', 'planning.inspect'], tmpDir);
const dottedResult = runMsdTools(['query', 'planning.inspect'], tmpDir);
assert.strictEqual(dottedResult.success, true, `expected success: ${dottedResult.error}`);
const dotted = JSON.parse(dottedResult.output);
@@ -371,14 +371,14 @@ describe('planning inspect — dispatch and usage', () => {
test('rejectsPlanningFamilyWithNoSubcommand', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
const result = runGsdTools(['query', 'planning'], tmpDir);
const result = runMsdTools(['query', 'planning'], tmpDir);
assert.strictEqual(result.success, false);
});
test('rejectsUnknownPlanningSubcommand', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
const result = runGsdTools(['query', 'planning', 'bogus'], tmpDir);
const result = runMsdTools(['query', 'planning', 'bogus'], tmpDir);
assert.strictEqual(result.success, false);
});
@@ -458,11 +458,11 @@ describe('planning inspect — dispatch and usage', () => {
// Row 15: every usage/dispatch failure in rows 7-11 must carry a TYPED
// `reason` under `--json-errors` — never require a caller to regex the
// human `message` prose.
const noSubcommand = runGsdTools(['query', 'planning', '--json-errors'], tmpDir);
const noSubcommand = runMsdTools(['query', 'planning', '--json-errors'], tmpDir);
assert.strictEqual(noSubcommand.success, false);
assert.strictEqual(JSON.parse(noSubcommand.error).reason, 'sdk_unknown_command');
const unknownSubcommand = runGsdTools(['query', 'planning', 'bogus', '--json-errors'], tmpDir);
const unknownSubcommand = runMsdTools(['query', 'planning', 'bogus', '--json-errors'], tmpDir);
assert.strictEqual(unknownSubcommand.success, false);
assert.strictEqual(JSON.parse(unknownSubcommand.error).reason, 'sdk_unknown_command');
@@ -648,7 +648,7 @@ describe('planning inspect — degradation and scope', () => {
// Row 20: ROADMAP.md deliberately not written (STATE.md alone is not
// enough to scope a milestone). getMilestoneInfo's own absent-file path
// reports SCOPE.UNREADABLE, not COMPLETE.
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
const payload = parseInspect(tmpDir);
assert.notStrictEqual(payload.milestone.scope, 'complete');
@@ -658,7 +658,7 @@ describe('planning inspect — degradation and scope', () => {
test('doesNotInventAMilestoneVersionForFreeFormRoadmap', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning']);
writeRoadmap(tmpDir, [
'# Project Roadmap',
'',
@@ -680,7 +680,7 @@ describe('planning inspect — degradation and scope', () => {
test('reportsTruncatedIdentityForProseOnlyVersionToken', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning']);
writeRoadmap(tmpDir, [
'# Project Roadmap',
'',
@@ -704,7 +704,7 @@ describe('planning inspect — degradation and scope', () => {
// Portability" — the milestone name must derive from the heading's OWN
// version token ("Portability"), never the raw remainder text after a
// naive prefix strip (".1 — Portability").
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v2.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v2.0']);
writeRoadmap(tmpDir, [
'## v2.0.1 — Portability',
'',
@@ -1589,7 +1589,7 @@ describe('planning inspect — evidence kept separate, never folded', () => {
writeCustomUatFile(phaseDir, '1-UAT-clean.md', 'complete', CLEAN_UAT_BODY);
writeCustomUatFile(phaseDir, '1-UAT-shortfall.md', 'complete', SHORTFALL_UAT_BODY);
const planningInspectLib = require('../gsd-core/bin/lib/planning-inspect.cjs');
const planningInspectLib = require('../msd-core/bin/lib/planning-inspect.cjs');
const originalReaddirSync = fs.readdirSync;
t.mock.method(fs, 'readdirSync', function mockedReaddirSync(target, ...rest) {
const result = originalReaddirSync.call(this, target, ...rest);
@@ -1643,7 +1643,7 @@ describe('planning inspect — evidence kept separate, never folded', () => {
// equality never matches. Three phases distinguish all three checkbox
// states so none of them collapses into another: ticked (true), unticked
// (false), and no checkbox bullet at all (null, NOT false).
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -1688,7 +1688,7 @@ describe('planning inspect — per-phase goal and dependency evidence', () => {
test('reportsThePhaseHeadingProseAsGoalWithCompleteScope', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -1712,7 +1712,7 @@ describe('planning inspect — per-phase goal and dependency evidence', () => {
test('reportsDependsOnPhaseTokensAsAStringArray', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -1756,7 +1756,7 @@ describe('planning inspect — per-phase goal and dependency evidence', () => {
test('excludesTheDependsOnAnnotationFromGoalEvenThoughItIsSurfacedSeparately', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -1785,7 +1785,7 @@ describe('planning inspect — per-phase goal and dependency evidence', () => {
test('excludesThePlansChecklistFromGoalProse', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -1813,7 +1813,7 @@ describe('planning inspect — per-phase goal and dependency evidence', () => {
test('reportsNullGoalWithCompleteScopeWhenTheSectionIsPureMetadata', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -1854,7 +1854,7 @@ describe('planning inspect — percent withholding', () => {
test('emitsZeroPercentNotNullNotHundredForAZeroPhaseButReadableProject', (t) => {
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, ['## v1.0 Current 🚧', '']);
// No phase directories at all.
@@ -1871,7 +1871,7 @@ describe('planning inspect — percent withholding', () => {
t.after(() => cleanup(tmpDir));
buildHealthyFixture(tmpDir);
const planningInspectLib = require('../gsd-core/bin/lib/planning-inspect.cjs');
const planningInspectLib = require('../msd-core/bin/lib/planning-inspect.cjs');
const phasesDir = phasesDirOf(tmpDir);
const originalReaddirSync = fs.readdirSync;
@@ -1905,7 +1905,7 @@ describe('planning inspect — fault isolation and combinations', () => {
fs.mkdirSync(nestedDir, { recursive: true });
writeAbs(path.join(nestedDir, 'PLAN-01-x.md'), ['<objective>', 'a', '</objective>', '<tasks></tasks>'].join('\n'));
const planningInspectLib = require('../gsd-core/bin/lib/planning-inspect.cjs');
const planningInspectLib = require('../msd-core/bin/lib/planning-inspect.cjs');
const originalReaddirSync = fs.readdirSync;
t.mock.method(fs, 'readdirSync', function mockedReaddirSync(target, ...rest) {
if (target === nestedDir) {
@@ -1978,7 +1978,7 @@ describe('planning inspect — fault isolation and combinations', () => {
// plan in the SAME phase must be entirely unaffected.
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
const secretDir = createTempDir('gsd-2790-secret-');
const secretDir = createTempDir('msd-2790-secret-');
t.after(() => cleanup(secretDir));
const secretFile = path.join(secretDir, 'secret.txt');
const sentinel = 'TOP_SECRET_OBJECTIVE_VALUE_9f3c1a';
@@ -2025,9 +2025,9 @@ describe('planning inspect — fault isolation and combinations', () => {
// so via the relocated location rather than the literal `cwd/.planning`
// path. Without this test, the fix above could silently regress into
// rejecting every document in such a project.
const bareDir = createTempDir('gsd-2790-bare-');
const bareDir = createTempDir('msd-2790-bare-');
t.after(() => cleanup(bareDir));
const realPlanningDir = createTempDir('gsd-2790-real-planning-');
const realPlanningDir = createTempDir('msd-2790-real-planning-');
t.after(() => cleanup(realPlanningDir));
try {
fs.symlinkSync(realPlanningDir, path.join(bareDir, '.planning'));
@@ -2070,7 +2070,7 @@ describe('planning inspect — fault isolation and combinations', () => {
// fraction from only the phases that happened to be readable.
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧', '', '### Phase 1: A', '', '### Phase 2: B', '',
]);
@@ -2081,7 +2081,7 @@ describe('planning inspect — fault isolation and combinations', () => {
writeSummaryDoc(phaseBDir, '2-01-SUMMARY.md', [], ['# s', '', '## Files Created/Modified']);
writeVerification(phaseBDir, '02', 'passed');
const planningInspectLib = require('../gsd-core/bin/lib/planning-inspect.cjs');
const planningInspectLib = require('../msd-core/bin/lib/planning-inspect.cjs');
const originalReaddirSync = fs.readdirSync;
t.mock.method(fs, 'readdirSync', function mockedReaddirSync(target, ...rest) {
if (target === phaseADir) {
@@ -2105,7 +2105,7 @@ describe('planning inspect — fault isolation and combinations', () => {
// ─── 7c. The 50 KB @file: spill boundary (io.cjs's own `> 50000` predicate) ──
const ioLib = require('../gsd-core/bin/lib/io.cjs');
const ioLib = require('../msd-core/bin/lib/io.cjs');
/**
* Build a JSON payload whose `serializeForOutput` byte length is EXACTLY
@@ -2146,7 +2146,7 @@ describe('planning inspect — the 50 KB @file: spill boundary', () => {
assert.strictEqual(ioLib.serializeForOutput(payload).length > 50000, true);
// Row 62, part B: a genuinely oversized END-TO-END fixture through the
// real CLI — proving `resolveAtFileOutput` (gsd-tools.cjs) transparently
// real CLI — proving `resolveAtFileOutput` (msd-tools.cjs) transparently
// resolves the `@file:` spill back into full JSON on stdout, so the
// caller never has to know the spill happened.
const tmpDir = createTempProject();
@@ -2341,15 +2341,15 @@ describe('planning inspect — hostile input', () => {
t.after(() => cleanup(tmpDir));
buildHealthyFixture(tmpDir);
const result = runGsdTools(['query', 'planning', 'inspect'], tmpDir, { GSD_FAKE_TOKEN: 'supersecretvalue' });
const result = runMsdTools(['query', 'planning', 'inspect'], tmpDir, { MSD_FAKE_TOKEN: 'supersecretvalue' });
assert.strictEqual(result.success, true, `expected success: ${result.error}`);
assert.ok(!result.output.includes('supersecretvalue'));
assert.ok(!(result.error || '').includes('supersecretvalue'));
});
test('producesIdenticalPayloadForCrlfDocumentsAsForLfDocuments', (t) => {
const tmpLf = createTempProject('gsd-2790-lf-');
const tmpCrlf = createTempProject('gsd-2790-crlf-');
const tmpLf = createTempProject('msd-2790-lf-');
const tmpCrlf = createTempProject('msd-2790-crlf-');
t.after(() => {
cleanup(tmpLf);
cleanup(tmpCrlf);
@@ -2366,7 +2366,7 @@ describe('planning inspect — hostile input', () => {
test('toleratesLoneCarriageReturnLineEndings', (t) => {
// Row 64: old-Mac lone `\r` line endings (no `\n` at all). No crash; the
// command's output is deterministic across two runs.
const tmpDir = createTempProject('gsd-2790-cr-');
const tmpDir = createTempProject('msd-2790-cr-');
t.after(() => cleanup(tmpDir));
buildHealthyFixture(tmpDir, '\r');
@@ -2459,16 +2459,16 @@ describe('planning inspect — hostile input', () => {
].join('\n'));
// Assert via `--pick schema_version` rather than the full JSON payload.
// gsd-tools handles this correctly end-to-end: output() spills the >50KB
// msd-tools handles this correctly end-to-end: output() spills the >50KB
// JSON to a tmpfile and resolves the @file: reference back to stdout, so
// the full 1 MB document IS read and parsed — but resolved stdout is then
// well over runGsdTools's subprocess maxBuffer, which makes the HELPER
// well over runMsdTools's subprocess maxBuffer, which makes the HELPER
// report BUFFER_OVERFLOW/ENOBUFS. That failure is the test harness's
// buffer ceiling, not the product. `--pick` makes gsd-tools extract a
// buffer ceiling, not the product. `--pick` makes msd-tools extract a
// single small field and print only that, so stdout stays tiny while the
// full 1 MB document is still read and parsed end to end — proving the
// command completes successfully on a pathologically long value without
// measuring runGsdTools's maxBuffer instead of the product.
// measuring runMsdTools's maxBuffer instead of the product.
const result = runInspect(tmpDir, ['--pick', 'schema_version']);
assert.strictEqual(result.success, true, `expected success for a 1MB value: ${result.error}`);
assert.strictEqual(result.output, '1', 'schema_version must round-trip as 1 through --pick');
@@ -2480,7 +2480,7 @@ describe('planning inspect — hostile input', () => {
// Row 71: Unicode + RTL headings and names must round-trip byte-identical
// into the payload — no width/parse corruption.
const rtlName = 'المصادقة'; // Arabic: "Authentication"
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -2522,7 +2522,7 @@ describe('planning inspect — cross-consumer parity with phase-plan-index', ()
]);
const inspectPayload = parseInspect(tmpDir);
const planIndexResult = runGsdTools(['phase-plan-index', '1', '--raw'], tmpDir);
const planIndexResult = runMsdTools(['phase-plan-index', '1', '--raw'], tmpDir);
assert.strictEqual(planIndexResult.success, true, `phase-plan-index should succeed: ${planIndexResult.error}`);
const planIndexPayload = JSON.parse(planIndexResult.output);
@@ -2559,7 +2559,7 @@ describe('planning inspect — cross-consumer parity with phase-plan-index', ()
]);
// No SUMMARY for 1-02 — it stays incomplete/runnable.
const result = runGsdTools(['phase-plan-index', '1', '--raw'], tmpDir);
const result = runMsdTools(['phase-plan-index', '1', '--raw'], tmpDir);
assert.strictEqual(result.success, true, `expected success: ${result.error}`);
const payload = JSON.parse(result.output);
@@ -2615,7 +2615,7 @@ const PLANNING_PROJECT_SHAPE_ARB = fc.record({
function buildDocumentShapedProject(cwd, cfg) {
if (cfg.hasState) {
writeState(cwd, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0'], [], cfg.eol);
writeState(cwd, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0'], [], cfg.eol);
}
if (cfg.hasRoadmap) {
const lines = ['## v1.0 Current 🚧', ''];
@@ -2660,7 +2660,7 @@ describe('planning inspect — property tests', () => {
fc.assert(
fc.property(PLANNING_PROJECT_SHAPE_ARB, (cfg) => {
const tmpDir = createTempProject('gsd-2790-prop-');
const tmpDir = createTempProject('msd-2790-prop-');
createdDirs.push(tmpDir);
buildDocumentShapedProject(tmpDir, cfg);
@@ -2682,7 +2682,7 @@ describe('planning inspect — property tests', () => {
// ─── 12. plan-document task-count parity (property, direct require) ──────────
const { parsePlanDocument } = require('../gsd-core/bin/lib/plan-document.cjs');
const { parsePlanDocument } = require('../msd-core/bin/lib/plan-document.cjs');
const TASK_COUNT_ARB = fc.record({
xmlCount: fc.integer({ min: 0, max: 5 }),
@@ -2779,13 +2779,13 @@ describe('planning inspect — phase-directory and verification-file containment
// sibling phase is entirely unaffected.
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
const externalDir = createTempDir('gsd-2790-external-phase-');
const externalDir = createTempDir('msd-2790-external-phase-');
t.after(() => cleanup(externalDir));
const sentinelFileName = 'TOP-SECRET-FILENAME-8f21ac.md';
const sentinelContent = 'TOP_SECRET_PHASE_CONTENT_4d81af';
fs.writeFileSync(path.join(externalDir, sentinelFileName), sentinelContent);
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',
@@ -2832,7 +2832,7 @@ describe('planning inspect — phase-directory and verification-file containment
// symlinked outside the planning root must never surface that value.
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
const externalDir = createTempDir('gsd-2790-external-verification-');
const externalDir = createTempDir('msd-2790-external-verification-');
t.after(() => cleanup(externalDir));
const sentinel = 'TOP_SECRET_STATUS_VALUE_c93af1';
const secretFile = path.join(externalDir, 'secret-status.md');
@@ -2878,7 +2878,7 @@ describe('planning inspect — phase-directory and verification-file containment
// proves for the WHOLE `.planning/` root, one level down at `phases/`.
const tmpDir = createTempProject();
t.after(() => cleanup(tmpDir));
writeState(tmpDir, ["gsd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeState(tmpDir, ["msd_state_version: '1.0'", 'status: planning', 'milestone: v1.0']);
writeRoadmap(tmpDir, [
'## v1.0 Current 🚧',
'',