integrate: sync appendix sources to v0.5 appendix table (00-10)
Integration arbitration, not a PR commit: v0.3/v0.4/v0.5 synced body changes into appendix chapters 00/02/04/06/07 while templates/roles/ sources stayed at v0.2, so check_appendix failed 6 chapters; and 09-ops/10-iteration chapters (v0.5) were invisible to the strict chapter regex because of the ', v0.5 new' title suffix, breaking the #214 matrix-vs-appendix test. Direction is sources follow the appendix (appendix is the tenant-visible authoritative version; never overwrite v0.5 text with v0.2). 09/10 headers normalized to strict form (suffix only); 09/10 sources split mechanically from the appendix; EXPECTED_IDS extended to 11 chapters in the checker and both appendix tests.
This commit is contained in:
1 parent
be41ad2c0a
commit
2720acef46
12 files changed
+302
-57
No files matched your search
@@ -8,14 +8,15 @@ script. The appendix was therefore unverifiable -- a drifted chapter
|
||||
would pass CI silently.
|
||||
|
||||
This file pins the repair, and nothing else:
|
||||
- tools/check_appendix.py passes on the real pack (all nine chapters
|
||||
match their templates/roles/ sources, CHANGELOG present and
|
||||
mentioning templates/roles/);
|
||||
- tools/check_appendix.py passes on the real pack (all eleven
|
||||
chapters match their templates/roles/ sources, CHANGELOG present
|
||||
and mentioning templates/roles/);
|
||||
- the same script FAILS (nonzero exit) on a temp copy with a source
|
||||
deleted, a source tampered, or an extra source added -- so a future
|
||||
"source missing" or "appendix drifted" state cannot slip through;
|
||||
- --emit output is exactly the nine headings plus the nine source
|
||||
bodies, so the spliced form is itself derived from the sources.
|
||||
- --emit output is exactly the eleven headings plus the eleven
|
||||
source bodies, so the spliced form is itself derived from the
|
||||
sources.
|
||||
|
||||
Scope guard: these tests never edit SKILL.md or the sources. A
|
||||
failure here is an editorial decision for the skill's own track
|
||||
@@ -38,7 +39,8 @@ SCRIPT = SKILL_DIR / "tools" / "check_appendix.py"
|
||||
|
||||
EXPECTED_IDS = ["00-coordinator", "01-product-manager", "02-architect",
|
||||
"03-designer", "04-client-developer", "05-backend",
|
||||
"06-qa", "07-acceptance", "08-shared-core"]
|
||||
"06-qa", "07-acceptance", "08-shared-core",
|
||||
"09-ops", "10-iteration"]
|
||||
|
||||
|
||||
def _run(skill_dir=None):
|
||||
@@ -66,7 +68,7 @@ class AppendixProvenanceTestCase(unittest.TestCase):
|
||||
self.assertEqual(
|
||||
result.returncode, 0,
|
||||
"校验脚本应在真实包上通过,stderr:%s" % result.stderr)
|
||||
self.assertIn("9 chapters match", result.stdout)
|
||||
self.assertIn("11 chapters match", result.stdout)
|
||||
|
||||
def test_missing_source_fails(self):
|
||||
skill = _temp_skill_copy(self)
|
||||
@@ -110,7 +112,7 @@ class AppendixProvenanceTestCase(unittest.TestCase):
|
||||
/ (cid + ".md")).read_text(encoding="utf-8")
|
||||
expected_parts.append(heading + "\n\n" + source.rstrip("\n"))
|
||||
self.assertEqual(result.stdout, "\n\n".join(expected_parts) + "\n",
|
||||
"--emit 输出须恰为 9 章标题 + 9 份源正文")
|
||||
"--emit 输出须恰为 11 章标题 + 11 份源正文")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
||||
Reference in new issue
Block a user