@elvis1513/auto-coding-skill 4.3.0 → 4.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +41 -5
- package/cli/assets/managed-install.json +1 -1
- package/cli/assets/skill/data/policies/feedback-resolutions-v1.json +20 -0
- package/cli/assets/skill/data/policies/workflow-migrations-v1.json +2 -2
- package/cli/assets/skill/data/templates/ENGINEERING.md +2 -2
- package/cli/assets/skill/data/templates/bridges/AGENTS.md +5 -3
- package/cli/assets/skill/scripts/ap.py +351 -75
- package/cli/assets/skill/scripts/install_integrity.py +7 -7
- package/cli/assets/skill/scripts/scaffold_templates.py +53 -6
- package/cli/src/index.js +76 -5
- package/cli/tests/ap_profiles_test.py +26 -0
- package/cli/tests/core_shell_test.py +5 -5
- package/cli/tests/index.test.js +164 -35
- package/package.json +1 -1
package/cli/tests/index.test.js
CHANGED
|
@@ -367,6 +367,18 @@ function testInitFullyConvergesExistingProject() {
|
|
|
367
367
|
writeFile(path.join(repo, "docs", "architecture", "adr", "0042-project-choice.md"), "# ADR-0042\n\nKeep me.\n");
|
|
368
368
|
writeFile(path.join(repo, "docs", "interfaces", "event-contracts.md"), "# Events\n\nKeep me.\n");
|
|
369
369
|
writeFile(path.join(repo, "docs", "project", "operations.md"), "# Project operations\n\nKeep me.\n");
|
|
370
|
+
const projectAssets = new Map([
|
|
371
|
+
["docs/architecture/diagrams/system.svg", Buffer.from("<svg>architecture</svg>\n")],
|
|
372
|
+
["docs/bugs/attachments/trace.bin", Buffer.from([0, 1, 2, 255])],
|
|
373
|
+
["docs/deployment/assets/values.yaml", Buffer.from("replicas: 2\n")],
|
|
374
|
+
["docs/design/T0055-login-comparison.png", Buffer.from([137, 80, 78, 71, 0, 255])],
|
|
375
|
+
["docs/interfaces/schemas/event.json", Buffer.from('{"type":"object"}\n')],
|
|
376
|
+
["docs/project/assets/logo.bin", Buffer.from([10, 20, 30, 40])],
|
|
377
|
+
["docs/reviews/evidence/chart.svg", Buffer.from("<svg>review</svg>\n")],
|
|
378
|
+
["docs/testing/fixtures/sample.dat", Buffer.from("fixture\u0000bytes")],
|
|
379
|
+
]);
|
|
380
|
+
for (const [relative, bytes] of projectAssets) writeFile(path.join(repo, relative), bytes);
|
|
381
|
+
writeFile(path.join(repo, "docs", "legacy", "orphan.bin"), Buffer.from([7, 8, 9]));
|
|
370
382
|
const skillFeedback = path.join(repo, "docs", "skill-feedback", "reports", "2026-07-18-review-timeout-a13f82c1.md");
|
|
371
383
|
const skillFeedbackContent = "project-owned feedback bytes\n";
|
|
372
384
|
writeFile(skillFeedback, skillFeedbackContent);
|
|
@@ -374,6 +386,13 @@ function testInitFullyConvergesExistingProject() {
|
|
|
374
386
|
writeFile(path.join(repo, ".agents", "agents", "custom.toml"), 'name = "custom"\n');
|
|
375
387
|
writeFile(path.join(repo, ".agents", "skills", "auto-coding-skill", "obsolete.txt"), "obsolete\n");
|
|
376
388
|
|
|
389
|
+
const dryRun = run("node", [cli, "sync", "--projects", repo, "--dry-run", "--json"]);
|
|
390
|
+
const dryActions = JSON.parse(dryRun.stdout).results[0].actions;
|
|
391
|
+
for (const [relative, bytes] of projectAssets) {
|
|
392
|
+
assert(!dryActions.some(item => item.path === relative && item.action === "would-delete"), `${relative}: dry-run must preserve project-owned assets`);
|
|
393
|
+
assert(fs.readFileSync(path.join(repo, relative)).equals(bytes), `${relative}: dry-run must preserve bytes`);
|
|
394
|
+
}
|
|
395
|
+
|
|
377
396
|
run("node", [cli, "init"], { cwd: repo });
|
|
378
397
|
const installedDocs = listProjectFiles(path.join(repo, "docs"))
|
|
379
398
|
.map(file => path.relative(repo, file).split(path.sep).join("/"))
|
|
@@ -386,6 +405,7 @@ function testInitFullyConvergesExistingProject() {
|
|
|
386
405
|
"docs/project/auto-coding-skill.yaml",
|
|
387
406
|
"docs/project/operations.md",
|
|
388
407
|
"docs/skill-feedback/reports/2026-07-18-review-timeout-a13f82c1.md",
|
|
408
|
+
...projectAssets.keys(),
|
|
389
409
|
].sort();
|
|
390
410
|
assert(JSON.stringify(installedDocs) === JSON.stringify(expectedInstalledDocs), `docs framework must converge while preserving valid artifacts: ${installedDocs.join(", ")}`);
|
|
391
411
|
const converged = fs.readFileSync(engineering, "utf8");
|
|
@@ -402,7 +422,8 @@ function testInitFullyConvergesExistingProject() {
|
|
|
402
422
|
}
|
|
403
423
|
assert(exists(path.join(repo, ".agents", "agents", "custom.toml")), "project-owned custom agents must survive init");
|
|
404
424
|
assert(!exists(path.join(repo, ".agents", "skills", "auto-coding-skill", "obsolete.txt")), "extra Skill files must be removed");
|
|
405
|
-
assert(exists(path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
425
|
+
assert(exists(path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "legacy", "old-taskbook.md")), "removed docs must be archived outside active docs");
|
|
426
|
+
assert(exists(path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "legacy", "orphan.bin")), "unowned legacy binary assets must still be archived");
|
|
406
427
|
assert(fs.readFileSync(structureStandard, "utf8") === customStructureStandard, "init must preserve a project-owned structure standard");
|
|
407
428
|
assert(fs.readFileSync(path.join(repo, "docs", "architecture", "adr", "0042-project-choice.md"), "utf8").includes("Keep me"), "numbered ADR artifacts must survive init");
|
|
408
429
|
assert(fs.readFileSync(path.join(repo, "docs", "architecture", "system-context.md"), "utf8").includes("Keep me"), "architecture artifacts must survive init");
|
|
@@ -410,12 +431,18 @@ function testInitFullyConvergesExistingProject() {
|
|
|
410
431
|
assert(fs.readFileSync(path.join(repo, "docs", "project", "operations.md"), "utf8").includes("Keep me"), "project fact documents promised by the manifest must survive init");
|
|
411
432
|
assert(fs.readFileSync(skillFeedback, "utf8") === skillFeedbackContent, "project Skill feedback must survive init byte-for-byte");
|
|
412
433
|
assert(fs.readFileSync(projectConfigPath(repo)).equals(overlayBefore), "init must preserve the project configuration overlay byte-for-byte");
|
|
434
|
+
for (const [relative, bytes] of projectAssets) {
|
|
435
|
+
assert(fs.readFileSync(path.join(repo, relative)).equals(bytes), `${relative}: init must preserve project-owned bytes`);
|
|
436
|
+
}
|
|
413
437
|
|
|
414
438
|
run("node", [cli, "init"], { cwd: repo });
|
|
415
439
|
assert(fs.readFileSync(engineering, "utf8") === converged, "repeated init must be byte-idempotent for ENGINEERING.md");
|
|
416
440
|
assert(fs.readFileSync(projectConfigPath(repo)).equals(overlayBefore), "repeated init must preserve the project configuration overlay byte-for-byte");
|
|
417
441
|
assert(fs.readFileSync(structureStandard, "utf8") === customStructureStandard, "repeated init must preserve the project structure standard byte-for-byte");
|
|
418
442
|
assert(fs.readFileSync(skillFeedback, "utf8") === skillFeedbackContent, "repeated init must preserve project Skill feedback byte-for-byte");
|
|
443
|
+
for (const [relative, bytes] of projectAssets) {
|
|
444
|
+
assert(fs.readFileSync(path.join(repo, relative)).equals(bytes), `${relative}: repeated init must preserve project-owned bytes`);
|
|
445
|
+
}
|
|
419
446
|
const secondDocs = listProjectFiles(path.join(repo, "docs"))
|
|
420
447
|
.map(file => path.relative(repo, file).split(path.sep).join("/"))
|
|
421
448
|
.sort();
|
|
@@ -468,6 +495,39 @@ function testStructureBlockWarningsDefaultsPreserveAndConverge() {
|
|
|
468
495
|
);
|
|
469
496
|
}
|
|
470
497
|
|
|
498
|
+
function testProjectDocumentationSpecialFilesFailBeforeWrites() {
|
|
499
|
+
if (process.platform === "win32") return;
|
|
500
|
+
const repo = tmpdir("docs-special-files");
|
|
501
|
+
run("node", [cli, "init"], { cwd: repo });
|
|
502
|
+
const skill = path.join(repo, ".agents", "skills", "auto-coding-skill", "SKILL.md");
|
|
503
|
+
const sentinel = "stale-skill-must-survive-rejected-docs-preflight\n";
|
|
504
|
+
writeFile(skill, sentinel);
|
|
505
|
+
|
|
506
|
+
const externalFile = path.join(tmpdir("docs-special-target"), "external.png");
|
|
507
|
+
writeFile(externalFile, "external-target\n");
|
|
508
|
+
const linkedFile = path.join(repo, "docs", "design", "linked.png");
|
|
509
|
+
fs.symlinkSync(externalFile, linkedFile);
|
|
510
|
+
let rejected = run("node", [cli, "sync", "--projects", repo], { check: false });
|
|
511
|
+
assert(rejected.status !== 0 && rejected.stderr.includes("regular non-symlink files"), "project document file symlinks must fail before writes");
|
|
512
|
+
assert(fs.readFileSync(skill, "utf8") === sentinel && fs.readFileSync(externalFile, "utf8") === "external-target\n", "rejected file symlink must not mutate managed or external files");
|
|
513
|
+
fs.unlinkSync(linkedFile);
|
|
514
|
+
|
|
515
|
+
const externalDir = tmpdir("docs-special-directory-target");
|
|
516
|
+
const linkedDir = path.join(repo, "docs", "reviews", "linked-assets");
|
|
517
|
+
fs.symlinkSync(externalDir, linkedDir);
|
|
518
|
+
rejected = run("node", [cli, "sync", "--projects", repo], { check: false });
|
|
519
|
+
assert(rejected.status !== 0 && rejected.stderr.includes("regular non-symlink files"), "project document directory symlinks must fail before writes");
|
|
520
|
+
assert(fs.readFileSync(skill, "utf8") === sentinel && fs.readdirSync(externalDir).length === 0, "rejected directory symlink must preserve both roots");
|
|
521
|
+
fs.unlinkSync(linkedDir);
|
|
522
|
+
|
|
523
|
+
const fifo = path.join(repo, "docs", "testing", "fixture.pipe");
|
|
524
|
+
run("mkfifo", [fifo]);
|
|
525
|
+
rejected = run("node", [cli, "sync", "--projects", repo], { check: false });
|
|
526
|
+
assert(rejected.status !== 0 && rejected.stderr.includes("regular non-symlink files"), "project document FIFOs must fail before writes");
|
|
527
|
+
assert(fs.readFileSync(skill, "utf8") === sentinel, "rejected special files must preserve managed bytes");
|
|
528
|
+
fs.unlinkSync(fifo);
|
|
529
|
+
}
|
|
530
|
+
|
|
471
531
|
function testManagedPolicySummaryPreservesProjectConfiguration() {
|
|
472
532
|
const repo = tmpdir("managed-policy-summary");
|
|
473
533
|
run("node", [cli, "init"], { cwd: repo });
|
|
@@ -478,12 +538,12 @@ function testManagedPolicySummaryPreservesProjectConfiguration() {
|
|
|
478
538
|
const legacySummary = "- `structure` and `optimization`: advisory architecture and no-new-debt policy.";
|
|
479
539
|
const installedOldDefault = current
|
|
480
540
|
.replace(/^ skill_version:.*$/m, " skill_version: 4.2.5")
|
|
481
|
-
.replace("managed-workflow:start version=4.3.
|
|
541
|
+
.replace("managed-workflow:start version=4.3.2", "managed-workflow:start version=4.2.5")
|
|
482
542
|
.replace(neutralSummary, legacySummary);
|
|
483
543
|
installTrustedEngineeringDefault(repo, installedOldDefault, "4.2.5");
|
|
484
544
|
const customized = current
|
|
485
545
|
.replace(/^ skill_version:.*$/m, " skill_version: 4.2.5")
|
|
486
|
-
.replace("managed-workflow:start version=4.3.
|
|
546
|
+
.replace("managed-workflow:start version=4.3.2", "managed-workflow:start version=4.2.5")
|
|
487
547
|
.replace(neutralSummary, legacySummary)
|
|
488
548
|
.replace(/^ enforcement:.*$/m, " enforcement: blocking")
|
|
489
549
|
.replace(" block_warnings: false", " block_warnings: true")
|
|
@@ -502,7 +562,7 @@ function testManagedPolicySummaryPreservesProjectConfiguration() {
|
|
|
502
562
|
const upgraded = fs.readFileSync(engineering, "utf8");
|
|
503
563
|
const managedAfterUpgrade = readEngineeringConfig(engineering);
|
|
504
564
|
const afterUpgrade = readEffectiveConfig(repo);
|
|
505
|
-
assert(managedAfterUpgrade.workflow?.skill_version === "4.3.
|
|
565
|
+
assert(managedAfterUpgrade.workflow?.skill_version === "4.3.2", "init must upgrade the managed workflow version");
|
|
506
566
|
assert(canonicalJson(afterUpgrade.structure) === canonicalJson(beforeUpgrade.structure), "init must preserve the complete project structure policy");
|
|
507
567
|
assert(canonicalJson(afterUpgrade.optimization) === canonicalJson(beforeUpgrade.optimization), "init must preserve the complete project optimization policy");
|
|
508
568
|
assert(upgraded.includes(neutralSummary), "upgraded managed text must defer to frontmatter policy");
|
|
@@ -580,11 +640,11 @@ function testMinimalInitConvergesWithinBudget() {
|
|
|
580
640
|
assert(files.length <= 40, `minimal scaffold file budget exceeded: ${files.length}`);
|
|
581
641
|
// Integrity, staging, fail-closed classification, immutable Reviewer snapshots,
|
|
582
642
|
// bounded runtime supervision, failure-evidence binding, contract helpers,
|
|
583
|
-
// effective-config overlay parsing/migration, metadata-only
|
|
584
|
-
// collection, and the language-aware structure scanner are executable
|
|
643
|
+
// effective-config overlay parsing/migration, release-aware metadata-only
|
|
644
|
+
// feedback lifecycle collection, and the language-aware structure scanner are executable
|
|
585
645
|
// support code, not prompt context. Keep a measured ceiling while leaving
|
|
586
646
|
// safety checks readable.
|
|
587
|
-
assert(lines <=
|
|
647
|
+
assert(lines <= 20500, `minimal scaffold line budget exceeded: ${lines}`);
|
|
588
648
|
const engineering = fs.readFileSync(path.join(repo, "docs", "ENGINEERING.md"), "utf8");
|
|
589
649
|
const managedConfig = readEngineeringConfig(path.join(repo, "docs", "ENGINEERING.md"));
|
|
590
650
|
assert(managedConfig.workflow?.profile === "auto", "engineering should enable adaptive profiles");
|
|
@@ -1153,7 +1213,7 @@ function testTamperedInstalledDefaultRejectsInitAndSyncWithoutWrites() {
|
|
|
1153
1213
|
const skill = path.join(repo, ".agents", "skills", "auto-coding-skill", "SKILL.md");
|
|
1154
1214
|
const oldDefault = fs.readFileSync(engineering, "utf8")
|
|
1155
1215
|
.replace(/^ skill_version:.*$/m, ' skill_version: "4.2.7"')
|
|
1156
|
-
.replace("managed-workflow:start version=4.3.
|
|
1216
|
+
.replace("managed-workflow:start version=4.3.2", "managed-workflow:start version=4.2.7");
|
|
1157
1217
|
installTrustedEngineeringDefault(repo, oldDefault, "4.2.7");
|
|
1158
1218
|
writeFile(engineering, oldDefault);
|
|
1159
1219
|
fs.unlinkSync(overlay);
|
|
@@ -1442,7 +1502,7 @@ function testArchiveFallbackCollisionsNeverLosePreviousContent() {
|
|
|
1442
1502
|
const engineering = path.join(repo, "docs", "ENGINEERING.md");
|
|
1443
1503
|
fs.appendFileSync(engineering, "\n## Archive collision sentinel\n\nPreserve these ENGINEERING bytes.\n");
|
|
1444
1504
|
const previous = fs.readFileSync(engineering);
|
|
1445
|
-
const archiveDir = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
1505
|
+
const archiveDir = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs");
|
|
1446
1506
|
const preferred = path.join(archiveDir, "ENGINEERING.md");
|
|
1447
1507
|
const legacyDigest = path.join(archiveDir, `ENGINEERING-${digest12(previous)}.md`);
|
|
1448
1508
|
const occupiedPreferred = Buffer.from("occupied-engineering-default\n");
|
|
@@ -1472,7 +1532,7 @@ function testArchiveFallbackCollisionsNeverLosePreviousContent() {
|
|
|
1472
1532
|
".agents",
|
|
1473
1533
|
"archive",
|
|
1474
1534
|
"auto-coding-skill",
|
|
1475
|
-
"4.3.
|
|
1535
|
+
"4.3.2",
|
|
1476
1536
|
"docs",
|
|
1477
1537
|
"design",
|
|
1478
1538
|
);
|
|
@@ -1497,9 +1557,9 @@ function testArchiveFallbackCollisionsNeverLosePreviousContent() {
|
|
|
1497
1557
|
const agents = path.join(repo, "AGENTS.md");
|
|
1498
1558
|
const previous = Buffer.from("# Project AGENTS before sync\n\nPreserve this sync history.\n");
|
|
1499
1559
|
fs.writeFileSync(agents, previous);
|
|
1500
|
-
const archiveDir = path.join(repo, "
|
|
1501
|
-
const preferred = path.join(archiveDir, "AGENTS.
|
|
1502
|
-
const legacyDigest = path.join(archiveDir, `AGENTS
|
|
1560
|
+
const archiveDir = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2");
|
|
1561
|
+
const preferred = path.join(archiveDir, "AGENTS.md");
|
|
1562
|
+
const legacyDigest = path.join(archiveDir, `AGENTS-${digest12(previous)}.md`);
|
|
1503
1563
|
const occupiedPreferred = Buffer.from("occupied-sync-default\n");
|
|
1504
1564
|
const occupiedDigest = Buffer.from("occupied-sync-digest\n");
|
|
1505
1565
|
writeFile(preferred, occupiedPreferred);
|
|
@@ -1519,7 +1579,7 @@ function testArchiveFallbackCollisionsNeverLosePreviousContent() {
|
|
|
1519
1579
|
const agents = path.join(repo, "AGENTS.md");
|
|
1520
1580
|
const previous = Buffer.from("# Project AGENTS before init\n\nPreserve this init history.\n");
|
|
1521
1581
|
fs.writeFileSync(agents, previous);
|
|
1522
|
-
const archiveDir = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
1582
|
+
const archiveDir = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2");
|
|
1523
1583
|
const preferred = path.join(archiveDir, "AGENTS.md");
|
|
1524
1584
|
const legacyDigest = path.join(archiveDir, `AGENTS-${digest12(previous)}.md`);
|
|
1525
1585
|
const occupiedPreferred = Buffer.from("occupied-init-default\n");
|
|
@@ -2149,7 +2209,7 @@ function testCliInstallArchivesFeedbackTemplatesAndPreservesReports() {
|
|
|
2149
2209
|
writeFile(report, reportContent);
|
|
2150
2210
|
|
|
2151
2211
|
run("node", [cli, "init"], { cwd: repo });
|
|
2152
|
-
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
2212
|
+
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "skill-feedback", "README.md");
|
|
2153
2213
|
assert(fs.readFileSync(feedbackReadme, "utf8").includes("Auto Coding Skill Feedback"), "transactional init must install the managed feedback README");
|
|
2154
2214
|
assert(fs.readFileSync(archive, "utf8") === previousReadme, "transactional init must archive a pre-existing feedback README before replacement");
|
|
2155
2215
|
assert(fs.readFileSync(report, "utf8") === reportContent, "transactional init must preserve project feedback reports byte-for-byte");
|
|
@@ -2244,7 +2304,7 @@ function testManagedEngineeringInitIsAuthoritativeAndIdempotent() {
|
|
|
2244
2304
|
|
|
2245
2305
|
const engineering = path.join(repo, "docs", "ENGINEERING.md");
|
|
2246
2306
|
const initial = fs.readFileSync(engineering, "utf8");
|
|
2247
|
-
const startPattern = /<!-- auto-coding-skill:managed-workflow:start version=4\.3\.
|
|
2307
|
+
const startPattern = /<!-- auto-coding-skill:managed-workflow:start version=4\.3\.2 -->/;
|
|
2248
2308
|
const endMarker = "<!-- auto-coding-skill:managed-workflow:end -->";
|
|
2249
2309
|
assert(startPattern.test(initial), "new projects should include a versioned managed workflow marker");
|
|
2250
2310
|
assert(initial.includes(endMarker), "new projects should include the managed workflow end marker");
|
|
@@ -2258,21 +2318,21 @@ function testManagedEngineeringInitIsAuthoritativeAndIdempotent() {
|
|
|
2258
2318
|
const dryRun = run("node", [cli, "sync", "--projects", repo, "--dry-run", "--json"]);
|
|
2259
2319
|
const dryResult = JSON.parse(dryRun.stdout).results[0];
|
|
2260
2320
|
assert(dryResult.managedWorkflow.state === "stale", `dry-run should expose stale workflow state: ${dryRun.stdout}`);
|
|
2261
|
-
assert(dryResult.managedWorkflow.version === "4.3.
|
|
2321
|
+
assert(dryResult.managedWorkflow.version === "4.3.2", "dry-run should expose the target workflow version");
|
|
2262
2322
|
assert(dryResult.actions.some(item => item.action === "would-replace" && item.path === "docs/ENGINEERING.md"), "dry-run should plan exact replacement of the managed default document");
|
|
2263
2323
|
assert(fs.readFileSync(engineering, "utf8") === customized, "dry-run must not write ENGINEERING.md");
|
|
2264
2324
|
|
|
2265
2325
|
run("node", [cli, "init"], { cwd: repo });
|
|
2266
2326
|
const updated = fs.readFileSync(engineering, "utf8");
|
|
2267
2327
|
assert(!updated.includes("project note before") && !updated.includes("project note after"), "init must remove text outside the canonical ENGINEERING body");
|
|
2268
|
-
assert(updated.includes("version=4.3.
|
|
2328
|
+
assert(updated.includes("version=4.3.2"), "init should install the current managed workflow version");
|
|
2269
2329
|
assert(updated.includes("The frontmatter contract is:"), "init should refresh stale managed workflow content");
|
|
2270
2330
|
|
|
2271
2331
|
fillRequiredAccess(repo);
|
|
2272
2332
|
const status = run("node", [cli, "status", "--projects", repo, "--json"]);
|
|
2273
2333
|
const statusResult = JSON.parse(status.stdout).results[0];
|
|
2274
2334
|
assert(statusResult.managedWorkflow.state === "current", `status should expose current managed workflow state: ${status.stdout}`);
|
|
2275
|
-
assert(statusResult.managedWorkflow.version === "4.3.
|
|
2335
|
+
assert(statusResult.managedWorkflow.version === "4.3.2", "status should expose the installed managed workflow version");
|
|
2276
2336
|
|
|
2277
2337
|
const beforeSecondInit = fs.readFileSync(engineering, "utf8");
|
|
2278
2338
|
run("node", [cli, "init"], { cwd: repo });
|
|
@@ -2300,9 +2360,9 @@ function testLegacyEngineeringMigrationPreservesExistingBody() {
|
|
|
2300
2360
|
assert(dryResult.actions.some(item => item.action === "would-archive" && item.path.endsWith("/docs/ENGINEERING.md")), "custom legacy migration must plan archival before replacement");
|
|
2301
2361
|
run("node", [cli, "sync", "--projects", repo]);
|
|
2302
2362
|
const migrated = fs.readFileSync(engineering, "utf8");
|
|
2303
|
-
assert(migrated.includes("version=4.3.
|
|
2363
|
+
assert(migrated.includes("version=4.3.2"), "legacy migration should insert the current managed workflow");
|
|
2304
2364
|
assert(!migrated.includes(legacyNote), "legacy project text must not remain in the exact managed default document");
|
|
2305
|
-
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
2365
|
+
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "ENGINEERING.md");
|
|
2306
2366
|
assert(fs.readFileSync(archive, "utf8").includes(legacyNote), "legacy migration must preserve the complete previous body in history");
|
|
2307
2367
|
const stable = fs.readFileSync(engineering, "utf8");
|
|
2308
2368
|
run("node", [cli, "sync", "--projects", repo]);
|
|
@@ -2330,7 +2390,7 @@ function testOfficialLegacyEngineeringBodyIsReplacedWithoutDuplication() {
|
|
|
2330
2390
|
assert(migrated === canonicalEngineering, "official legacy migration must install the exact managed default document");
|
|
2331
2391
|
assert((migrated.match(/auto-coding-skill:managed-workflow:start/g) || []).length === 1, "official legacy migration should install exactly one managed workflow");
|
|
2332
2392
|
assert((migrated.match(/^## Execution profiles$/gm) || []).length === 0, "official legacy migration must remove the old duplicated workflow body");
|
|
2333
|
-
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
2393
|
+
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "ENGINEERING.md");
|
|
2334
2394
|
assert(fs.readFileSync(archive, "utf8").includes("## Execution profiles"), "official legacy body must remain available in the historical archive");
|
|
2335
2395
|
|
|
2336
2396
|
const stable = fs.readFileSync(engineering, "utf8");
|
|
@@ -2405,7 +2465,7 @@ function testManagedAgentsMigrationReplacesWholeFileAndArchivesPreviousRules() {
|
|
|
2405
2465
|
run("node", [cli, "sync", "--projects", repo]);
|
|
2406
2466
|
const agents = path.join(repo, "AGENTS.md");
|
|
2407
2467
|
const initial = fs.readFileSync(agents, "utf8");
|
|
2408
|
-
assert(initial.includes("managed-agents:start version=4.3.
|
|
2468
|
+
assert(initial.includes("managed-agents:start version=4.3.2"), "new projects should receive the versioned root AGENTS block");
|
|
2409
2469
|
|
|
2410
2470
|
const custom = [
|
|
2411
2471
|
"# Project rules",
|
|
@@ -2415,6 +2475,9 @@ function testManagedAgentsMigrationReplacesWholeFileAndArchivesPreviousRules() {
|
|
|
2415
2475
|
"",
|
|
2416
2476
|
].join("\n");
|
|
2417
2477
|
writeFile(agents, custom);
|
|
2478
|
+
const legacyActiveArchive = path.join(repo, "docs", "archive", "workflow", "AGENTS.pre-4.3.1.md");
|
|
2479
|
+
const legacyActiveArchiveBytes = Buffer.from("# Historical 4.3.1 AGENTS archive\n");
|
|
2480
|
+
writeFile(legacyActiveArchive, legacyActiveArchiveBytes);
|
|
2418
2481
|
const dryRun = run("node", [cli, "sync", "--projects", repo, "--dry-run", "--json"]);
|
|
2419
2482
|
const plan = JSON.parse(dryRun.stdout).results[0].managedAgentsDocument;
|
|
2420
2483
|
assert(plan.state === "legacy-custom", `unmarked custom AGENTS should be migrated: ${dryRun.stdout}`);
|
|
@@ -2424,16 +2487,25 @@ function testManagedAgentsMigrationReplacesWholeFileAndArchivesPreviousRules() {
|
|
|
2424
2487
|
|
|
2425
2488
|
run("node", [cli, "sync", "--projects", repo]);
|
|
2426
2489
|
const migrated = fs.readFileSync(agents, "utf8");
|
|
2427
|
-
assert(migrated.includes("managed-agents:start version=4.3.
|
|
2490
|
+
assert(migrated.includes("managed-agents:start version=4.3.2"), "AGENTS migration should install the current managed block");
|
|
2428
2491
|
assert(!migrated.includes("Preserve this repository-specific rule exactly."), "root AGENTS must contain no project-specific tail");
|
|
2429
2492
|
assert(!migrated.includes("must execute `commands.gate_full`"), "known official conflicting rule should be removed");
|
|
2430
2493
|
const canonical = fs.readFileSync(path.join(repoRoot, "cli", "assets", "skill", "data", "templates", "bridges", "AGENTS.md"), "utf8");
|
|
2431
2494
|
assert(migrated === canonical, "root AGENTS must be byte-identical to the packaged canonical file");
|
|
2432
|
-
const archive = path.join(repo, "
|
|
2495
|
+
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "AGENTS.md");
|
|
2433
2496
|
assert(fs.readFileSync(archive, "utf8").includes("Preserve this repository-specific rule exactly."), "previous AGENTS content must be archived once");
|
|
2497
|
+
assert(!exists(legacyActiveArchive), "legacy active-doc AGENTS archives must leave docs/archive during upgrade");
|
|
2498
|
+
const migratedLegacyArchiveDir = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "archive", "workflow");
|
|
2499
|
+
assert(
|
|
2500
|
+
listProjectFiles(migratedLegacyArchiveDir).some(file => fs.readFileSync(file).equals(legacyActiveArchiveBytes)),
|
|
2501
|
+
"legacy active-doc AGENTS archive bytes must survive under the managed archive root",
|
|
2502
|
+
);
|
|
2434
2503
|
const stable = fs.readFileSync(agents);
|
|
2435
2504
|
run("node", [cli, "sync", "--projects", repo]);
|
|
2436
2505
|
assert(fs.readFileSync(agents).equals(stable), "managed AGENTS sync should be idempotent");
|
|
2506
|
+
fillRequiredAccess(repo);
|
|
2507
|
+
const postUpgradeStatus = JSON.parse(run("node", [cli, "status", "--projects", repo, "--json"]).stdout).results[0];
|
|
2508
|
+
assert(postUpgradeStatus.ok === true && postUpgradeStatus.docsDiffs.length === 0, "status must be current immediately after AGENTS archive migration");
|
|
2437
2509
|
}
|
|
2438
2510
|
|
|
2439
2511
|
function testUnknownWorkflowConflictFailsWholeBatchBeforeWrites() {
|
|
@@ -2481,7 +2553,7 @@ function testEngineeringMarkerBoundaryIsNormalized() {
|
|
|
2481
2553
|
const normalized = fs.readFileSync(engineering, "utf8");
|
|
2482
2554
|
assert(normalized === current, "sync should restore the exact managed document when text is glued to its end marker");
|
|
2483
2555
|
assert(!normalized.includes("# Project-specific workflow"), "project workflow text must not remain in the managed default document");
|
|
2484
|
-
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
2556
|
+
const archive = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "ENGINEERING.md");
|
|
2485
2557
|
assert(fs.readFileSync(archive, "utf8").includes(`${marker}# Project-specific workflow`), "the malformed previous document must remain available in history");
|
|
2486
2558
|
}
|
|
2487
2559
|
|
|
@@ -2498,7 +2570,7 @@ function testEngineeringFrameworkRejectsAnyNonCanonicalWorkflowText() {
|
|
|
2498
2570
|
|
|
2499
2571
|
run("node", [cli, "init"], { cwd: repo });
|
|
2500
2572
|
assert(!fs.readFileSync(engineering, "utf8").includes("backend owns APIs"), "init must restore the canonical ENGINEERING body");
|
|
2501
|
-
const archived = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.
|
|
2573
|
+
const archived = path.join(repo, ".agents", "archive", "auto-coding-skill", "4.3.2", "docs", "ENGINEERING.md");
|
|
2502
2574
|
assert(fs.readFileSync(archived, "utf8").includes("backend owns APIs"), "removed project text should remain in non-authoritative history");
|
|
2503
2575
|
}
|
|
2504
2576
|
|
|
@@ -2510,12 +2582,12 @@ function testManagedInstallIntegrityIsBoundedAndRepairable() {
|
|
|
2510
2582
|
|
|
2511
2583
|
const manifestPath = path.join(repo, ".agents", "managed-install.json");
|
|
2512
2584
|
const manifest = JSON.parse(fs.readFileSync(manifestPath, "utf8"));
|
|
2513
|
-
assert(manifest.schema_version === 1 && manifest.skill_version === "4.3.
|
|
2585
|
+
assert(manifest.schema_version === 1 && manifest.skill_version === "4.3.2", "installed manifest must identify the release");
|
|
2514
2586
|
assert(manifest.entries.length > 0, "installed manifest must list managed files");
|
|
2515
2587
|
for (const entry of manifest.entries) {
|
|
2516
2588
|
assert(typeof entry.path === "string" && !path.isAbsolute(entry.path) && !entry.path.includes(".."), "manifest paths must be safe relative paths");
|
|
2517
2589
|
assert(/^[0-9a-f]{64}$/.test(entry.sha256), `${entry.path}: manifest hash must be sha256`);
|
|
2518
|
-
assert(entry.version === "4.3.
|
|
2590
|
+
assert(entry.version === "4.3.2" && typeof entry.executable === "boolean", `${entry.path}: version/executable metadata missing`);
|
|
2519
2591
|
}
|
|
2520
2592
|
assert(!manifest.managed_namespaces.some(item => item.path === ".agents" || item.path === "docs"), "manifest must not mirror entire project-owned trees");
|
|
2521
2593
|
|
|
@@ -2600,7 +2672,7 @@ function testSkillFeedbackCollectionIsBoundedReadOnlyAndMetadataOnly() {
|
|
|
2600
2672
|
"status: open",
|
|
2601
2673
|
'created_at: "2026-07-18T10:00:00+08:00"',
|
|
2602
2674
|
`project: ${project}`,
|
|
2603
|
-
"observed_skill_version: 4.2
|
|
2675
|
+
"observed_skill_version: 4.3.2",
|
|
2604
2676
|
"component: reviewer-runtime",
|
|
2605
2677
|
"kind: defect",
|
|
2606
2678
|
"impact: blocking",
|
|
@@ -2630,27 +2702,60 @@ function testSkillFeedbackCollectionIsBoundedReadOnlyAndMetadataOnly() {
|
|
|
2630
2702
|
"Managed runtime behavior reproduces outside project configuration.",
|
|
2631
2703
|
"",
|
|
2632
2704
|
].join("\n");
|
|
2705
|
+
const renderV2 = (project, reportId, privateMarker, options) => render(project, reportId, privateMarker)
|
|
2706
|
+
.replace("schema: auto-coding-skill-feedback/v1", "schema: auto-coding-skill-feedback/v2")
|
|
2707
|
+
.replace("status: open", `status: ${options.status ?? "open"}`)
|
|
2708
|
+
.replace('created_at: "2026-07-18T10:00:00+08:00"', 'created_at: "2026-07-18T10:00:00+08:00"\nupdated_at: "2026-07-19T10:00:00+08:00"')
|
|
2709
|
+
.replace("observed_skill_version: 4.3.2", `observed_skill_version: ${options.observed ?? "4.3.2"}\nlast_verified_skill_version: ${options.lastVerified ?? options.observed ?? "4.3.2"}`)
|
|
2710
|
+
.replace(signature, options.signature)
|
|
2711
|
+
.replace("export: metadata-only", `resolution: ${options.resolution ?? "pending"}\nexport: metadata-only`);
|
|
2633
2712
|
const firstReport = path.join(first, "docs", "skill-feedback", "reports", "2026-07-18-review-timeout-a13f82c1.md");
|
|
2634
2713
|
const firstOtherReport = path.join(first, "docs", "skill-feedback", "reports", "2026-07-18-installer-gap-c35fa4e3.md");
|
|
2635
2714
|
const secondReport = path.join(second, "docs", "skill-feedback", "reports", "2026-07-18-review-timeout-b24f93d2.md");
|
|
2715
|
+
const closedReport = path.join(third, "docs", "skill-feedback", "reports", "2026-07-18-resolved-gap-d45fa4e3.md");
|
|
2716
|
+
const fixedReport = path.join(first, "docs", "skill-feedback", "reports", "2026-07-18-project-assets-fd5748e4.md");
|
|
2717
|
+
const rerouteReport = path.join(third, "docs", "skill-feedback", "reports", "2026-07-18-project-policy-a5eeb5eb.md");
|
|
2636
2718
|
const firstContent = render(path.basename(first), "ACSF-geesight-20260718-a13f82c1", "PRIVATE-BODY-FIRST");
|
|
2637
2719
|
const firstOtherContent = render(path.basename(first), "ACSF-geesight-20260718-c35fa4e3", "PRIVATE-BODY-OTHER")
|
|
2638
2720
|
.replaceAll(signature, `sha256:${"b".repeat(64)}`);
|
|
2639
2721
|
const secondContent = render(path.basename(second), "ACSF-xjmate-20260718-b24f93d2", "PRIVATE-BODY-SECOND");
|
|
2722
|
+
const closedContent = render(path.basename(third), "ACSF-closed-20260718-d45fa4e3", "PRIVATE-BODY-CLOSED")
|
|
2723
|
+
.replace("status: open", "status: resolved")
|
|
2724
|
+
.replaceAll(signature, `sha256:${"d".repeat(64)}`);
|
|
2725
|
+
const fixedContent = renderV2(path.basename(first), "ACSF-assets-20260718-fd5748e4", "PRIVATE-BODY-FIXED", {
|
|
2726
|
+
signature: "sha256:fd5748e4ae40e9f86762c4f62b3302bbbb2b8ae9661adf9e0e07a2327ccf7a36",
|
|
2727
|
+
observed: "4.3.0",
|
|
2728
|
+
lastVerified: "4.3.0",
|
|
2729
|
+
});
|
|
2730
|
+
const rerouteContent = renderV2(path.basename(third), "ACSF-policy-20260718-a5eeb5eb", "PRIVATE-BODY-REROUTE", {
|
|
2731
|
+
signature: "sha256:a5eeb5eb0ef5073dbeec726fa6c2016593b43eb1230171e3028f364c5b07bd86",
|
|
2732
|
+
});
|
|
2640
2733
|
writeFile(firstReport, firstContent);
|
|
2641
2734
|
writeFile(firstOtherReport, firstOtherContent);
|
|
2642
2735
|
writeFile(secondReport, secondContent);
|
|
2736
|
+
writeFile(closedReport, closedContent);
|
|
2737
|
+
writeFile(fixedReport, fixedContent);
|
|
2738
|
+
writeFile(rerouteReport, rerouteContent);
|
|
2643
2739
|
|
|
2644
2740
|
const collected = run("node", [cli, "feedback", "--projects", `${first},${second},${third}`, "--json"]);
|
|
2645
2741
|
const result = JSON.parse(collected.stdout);
|
|
2646
|
-
assert(result.schema === "auto-coding-skill-feedback-collection/
|
|
2647
|
-
assert(result.report_count === 3 && result.groups.length === 2, "feedback collection must
|
|
2742
|
+
assert(result.schema === "auto-coding-skill-feedback-collection/v2", "feedback collection must identify its active-only grouping schema");
|
|
2743
|
+
assert(result.report_count === 6 && result.active_report_count === 3 && result.groups.length === 2, "feedback collection must group only current active reports");
|
|
2744
|
+
assert(result.closed_report_count === 1 && result.lifecycle_counts.closed === 1, "closed v1 feedback must remain readable but leave active grouping");
|
|
2745
|
+
assert(result.action_required_count === 2, `catalog resolutions must produce bounded project actions: ${collected.stdout}`);
|
|
2746
|
+
const fixedAction = result.action_required.find(item => item.report_id === "ACSF-assets-20260718-fd5748e4");
|
|
2747
|
+
assert(fixedAction?.lifecycle === "verification-due" && fixedAction.recommended_action.includes("verify-fix"), "a project at the fixed release must verify and close its old report");
|
|
2748
|
+
const rerouteAction = result.action_required.find(item => item.report_id === "ACSF-policy-20260718-a5eeb5eb");
|
|
2749
|
+
assert(rerouteAction?.lifecycle === "reroute-due" && rerouteAction.recommended_action.includes("docs/project/auto-coding-skill.yaml"), "project preferences must route to the project overlay");
|
|
2750
|
+
const statusWithFeedback = run("node", [cli, "status", "--projects", first, "--json"], { check: false });
|
|
2751
|
+
const statusFeedback = JSON.parse(statusWithFeedback.stdout).results[0].feedback;
|
|
2752
|
+
assert(statusFeedback.available === true && statusFeedback.actionRequiredCount >= 1, "status must surface feedback maintenance without making it installation drift");
|
|
2648
2753
|
assert(result.projects.length === 3 && result.projects.every(item => item.source_project && item.project), "feedback collection must retain every explicit initialized project, including one with no reports");
|
|
2649
2754
|
const sharedGroup = result.groups.find(item => item.signature === signature);
|
|
2650
2755
|
assert(sharedGroup?.cross_project === true && sharedGroup.project_count === 2, "same signature from two explicit roots must be cross-project");
|
|
2651
2756
|
const localGroup = result.groups.find(item => item.signature === `sha256:${"b".repeat(64)}`);
|
|
2652
2757
|
assert(localGroup?.cross_project === false && localGroup.project_count === 1, "a separate one-project signature must remain a local candidate group");
|
|
2653
|
-
const rawReportDigests = [firstContent, firstOtherContent, secondContent]
|
|
2758
|
+
const rawReportDigests = [firstContent, firstOtherContent, secondContent, closedContent, fixedContent, rerouteContent]
|
|
2654
2759
|
.map(content => crypto.createHash("sha256").update(content).digest("hex"));
|
|
2655
2760
|
assert(result.metadata.every(item => !("content_sha256" in item) && item.size_bytes > 0), "feedback metadata must not export a hash oracle over private report bodies");
|
|
2656
2761
|
assert(rawReportDigests.every(digest => !collected.stdout.includes(digest)), "collector output must not expose raw report body digests");
|
|
@@ -2658,6 +2763,17 @@ function testSkillFeedbackCollectionIsBoundedReadOnlyAndMetadataOnly() {
|
|
|
2658
2763
|
assert(!collected.stdout.includes(first) && !collected.stdout.includes(second) && !collected.stdout.includes(third), "collector output must not expose absolute project roots");
|
|
2659
2764
|
assert(!exists(marker), "collector must never execute report content");
|
|
2660
2765
|
assert(fs.readFileSync(firstReport, "utf8") === firstContent && fs.readFileSync(firstOtherReport, "utf8") === firstOtherContent && fs.readFileSync(secondReport, "utf8") === secondContent, "collection must not modify reports");
|
|
2766
|
+
assert(fs.readFileSync(closedReport, "utf8") === closedContent && fs.readFileSync(fixedReport, "utf8") === fixedContent && fs.readFileSync(rerouteReport, "utf8") === rerouteContent, "lifecycle collection must preserve every project-owned report byte-for-byte");
|
|
2767
|
+
|
|
2768
|
+
writeFile(fixedReport, fixedContent.replace("last_verified_skill_version: 4.3.0", "last_verified_skill_version: 4.3.2"));
|
|
2769
|
+
let lifecycleCheck = JSON.parse(run("node", [cli, "feedback", "--projects", first, "--json"]).stdout);
|
|
2770
|
+
assert(lifecycleCheck.metadata.find(item => item.report_id === "ACSF-assets-20260718-fd5748e4")?.lifecycle === "regression-current", "a fixed signature reproduced on the fixed release must re-enter active triage as a regression");
|
|
2771
|
+
writeFile(fixedReport, fixedContent);
|
|
2772
|
+
|
|
2773
|
+
writeFile(firstOtherReport, firstOtherContent.replace("observed_skill_version: 4.3.2", "observed_skill_version: 4.2.8"));
|
|
2774
|
+
lifecycleCheck = JSON.parse(run("node", [cli, "feedback", "--projects", first, "--json"]).stdout);
|
|
2775
|
+
assert(lifecycleCheck.metadata.find(item => item.report_id === "ACSF-geesight-20260718-c35fa4e3")?.lifecycle === "recheck-due", "an unresolved v1 report from an older Skill version must require recheck");
|
|
2776
|
+
writeFile(firstOtherReport, firstOtherContent);
|
|
2661
2777
|
|
|
2662
2778
|
writeFile(secondReport, render("spoofed-project", "ACSF-xjmate-20260718-b24f93d2", "PRIVATE-BODY-SECOND"));
|
|
2663
2779
|
const spoofed = run("node", [cli, "feedback", "--projects", second, "--json"], { check: false });
|
|
@@ -2704,14 +2820,14 @@ function testSkillFeedbackCollectionIsBoundedReadOnlyAndMetadataOnly() {
|
|
|
2704
2820
|
}
|
|
2705
2821
|
|
|
2706
2822
|
function testReleaseVersionMarkersStayInSync() {
|
|
2707
|
-
const expected = "4.3.
|
|
2823
|
+
const expected = "4.3.2";
|
|
2708
2824
|
const pkg = JSON.parse(fs.readFileSync(path.join(repoRoot, "package.json"), "utf8"));
|
|
2709
2825
|
const lock = JSON.parse(fs.readFileSync(path.join(repoRoot, "package-lock.json"), "utf8"));
|
|
2710
2826
|
const policy = JSON.parse(fs.readFileSync(
|
|
2711
2827
|
path.join(repoRoot, "src", "auto-coding-skill", "data", "policies", "workflow-migrations-v1.json"),
|
|
2712
2828
|
"utf8",
|
|
2713
2829
|
));
|
|
2714
|
-
assert(pkg.version === expected, "package version must match the 4.3.
|
|
2830
|
+
assert(pkg.version === expected, "package version must match the 4.3.2 release");
|
|
2715
2831
|
assert(lock.version === expected && lock.packages[""].version === expected, "package-lock versions must match");
|
|
2716
2832
|
assert(policy.managed_versions.engineering === expected && policy.managed_versions.agents === expected, "managed workflow versions must match");
|
|
2717
2833
|
const manifest = JSON.parse(fs.readFileSync(path.join(repoRoot, "cli", "assets", "managed-install.json"), "utf8"));
|
|
@@ -2722,11 +2838,23 @@ function testReleaseVersionMarkersStayInSync() {
|
|
|
2722
2838
|
assert(manifest.preserved.includes("docs/architecture/structure-standard.md"), "manifest must declare the project structure standard preserved");
|
|
2723
2839
|
assert(manifest.entries.some(entry => entry.path === "docs/skill-feedback/README.md"), "feedback README must be exact-managed");
|
|
2724
2840
|
assert(manifest.entries.some(entry => entry.path === "docs/skill-feedback/_TEMPLATE-SKILL-FEEDBACK.md"), "feedback template must be exact-managed");
|
|
2841
|
+
assert(manifest.entries.some(entry => entry.path === ".agents/skills/auto-coding-skill/data/policies/feedback-resolutions-v1.json"), "feedback resolution catalog must be exact-managed");
|
|
2725
2842
|
assert(manifest.preserved.includes("docs/skill-feedback/reports/*.md"), "manifest must declare project feedback reports preserved");
|
|
2726
2843
|
assert(!manifest.managed_namespaces.some(item => item.path === "docs/skill-feedback"), "project feedback reports must stay outside managed namespaces");
|
|
2727
2844
|
assert(manifest.preserved.includes("docs/project/auto-coding-skill.yaml"), "manifest must declare the project configuration overlay preserved");
|
|
2728
2845
|
assert(!manifest.entries.some(entry => entry.path === "docs/project/auto-coding-skill.yaml"), "project configuration overlay must never be exact-managed");
|
|
2729
2846
|
assert(!manifest.managed_namespaces.some(item => item.path === "docs/project"), "project configuration overlay must stay outside managed namespaces");
|
|
2847
|
+
for (const root of ["architecture", "bugs", "deployment", "design", "interfaces", "project", "reviews", "testing"]) {
|
|
2848
|
+
assert(manifest.preserved.includes(`docs/${root}/** (except exact-managed entries)`), `manifest must preserve recursive project-owned ${root} assets`);
|
|
2849
|
+
}
|
|
2850
|
+
const resolutionCatalog = JSON.parse(fs.readFileSync(
|
|
2851
|
+
path.join(repoRoot, "src", "auto-coding-skill", "data", "policies", "feedback-resolutions-v1.json"),
|
|
2852
|
+
"utf8",
|
|
2853
|
+
));
|
|
2854
|
+
assert(resolutionCatalog.schema === "auto-coding-skill-feedback-resolutions/v1", "feedback resolution catalog schema must be stable");
|
|
2855
|
+
const resolutionSignatures = resolutionCatalog.entries.map(item => item.signature);
|
|
2856
|
+
assert(JSON.stringify(resolutionSignatures) === JSON.stringify([...new Set(resolutionSignatures)].sort()), "feedback resolution signatures must be unique and sorted");
|
|
2857
|
+
assert(resolutionCatalog.entries.every(item => /^\d+\.\d+\.\d+$/.test(item.effective_skill_version)), "feedback resolution releases must be stable SemVer");
|
|
2730
2858
|
const publishWorkflow = fs.readFileSync(path.join(repoRoot, ".github", "workflows", "npm-publish.yml"), "utf8");
|
|
2731
2859
|
const runtimeRequirements = fs.readFileSync(path.join(repoRoot, "src", "auto-coding-skill", "requirements.txt"), "utf8");
|
|
2732
2860
|
assert(publishWorkflow.includes("tags:\n - \"v*\""), "npm publish must run from version tag pushes");
|
|
@@ -2764,6 +2892,7 @@ function testProtocolResponsibilitiesStaySeparated() {
|
|
|
2764
2892
|
|
|
2765
2893
|
testInitFullyConvergesExistingProject();
|
|
2766
2894
|
testStructureBlockWarningsDefaultsPreserveAndConverge();
|
|
2895
|
+
testProjectDocumentationSpecialFilesFailBeforeWrites();
|
|
2767
2896
|
testManagedPolicySummaryPreservesProjectConfiguration();
|
|
2768
2897
|
testInitRejectsMissingPythonRuntimeBeforeWrites();
|
|
2769
2898
|
testDestVariants();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elvis1513/auto-coding-skill",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.2",
|
|
4
4
|
"description": "CLI installer for a delivery-first .agents workflow with adaptive Git isolation, routed changed-scope validation, risk-based review, push completion, and safe cleanup.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|