fix(3735): add surface to PROFILES.core (restore ADR-0011 expand contract) (#3744)

* test(3735): add failing test that PROFILES.core includes surface

Regression test asserting that resolveProfile({ modes: ['core'] }) includes
'surface' in its transitive closure — the ADR-0011 contract that --profile=core
users can expand via /gsd:surface enable <cluster>. Also updates stale
hardcoded skill-count assertions (7→8) across install-minimal*.test.cjs and
install-profiles-resolve.test.cjs to reflect the correct post-fix baseline.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix(3735): add 'surface' to PROFILES.core to restore ADR-0011 expand contract

PROFILES.core omitted 'surface', silently breaking the documented contract
in ADR-0011 that --profile=core users can expand their skill surface via
/gsd:surface enable <cluster>. The sub-command is only available if surface.md
is staged — which requires it to appear in the resolved set for the core profile.

Added 'surface' to both PROFILES.core and PROFILES.standard (standard is a
documented superset of core; omitting it from standard would break the
"standard must include all core skills" invariant and the resolveProfile tests).

The MINIMAL_SKILL_ALLOWLIST back-compat shim is derived from PROFILES.core so
it picks up surface automatically, ensuring --minimal and --core-only installs
also stage surface.md.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* chore(3735): update changeset to reference PR #3744

The fix commit landed with the linked-issue number as the pr: field
placeholder. Updating to the actual PR number now that the PR is open.

* docs(install-profiles): fix stale 'six skills' count in module header comment

After #3735 added surface to PROFILES.core the skill count became eight,
but the module-level comment still said "six skills covering the main project
loop". Update the description to reflect the correct count and reference the
ADR-0011 expand contract that surface fulfils.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Tom Boucher
2026-05-20 23:10:09 -04:00
committed by GitHub
parent 86e067924f
commit 26773bd669
5 changed files with 71 additions and 13 deletions

View File

@@ -313,7 +313,7 @@ describe('PROFILES map', () => {
assert.ok('full' in PROFILES, 'PROFILES.full missing');
});
test('PROFILES.core contains the 7 main-loop skills (including phase)', () => {
test('PROFILES.core contains the 8 main-loop skills (including phase and surface)', () => {
const core = PROFILES.core;
assert.ok(Array.isArray(core), 'core should be an array');
const sorted = [...core].sort();
@@ -324,6 +324,7 @@ describe('PROFILES map', () => {
'new-project',
'phase',
'plan-phase',
'surface',
'update',
]);
});
@@ -354,12 +355,13 @@ describe('resolveProfile', () => {
assert.strictEqual(result.skills, '*');
});
test('resolves core profile — returns 7+ skills, all base stems present', () => {
test('resolves core profile — returns 8+ skills, all base stems present', () => {
const manifest = loadSkillsManifest(REAL_COMMANDS_DIR);
const result = resolveProfile({ modes: ['core'], manifest });
assert.strictEqual(result.name, 'core');
assert.ok(result.skills instanceof Set, 'skills should be a Set');
assert.ok(result.skills.size >= 7, `core closure should have >=7 skills, got ${result.skills.size}`);
// core has 8 base skills (includes surface as of #3735).
assert.ok(result.skills.size >= 8, `core closure should have >=8 skills, got ${result.skills.size}`);
for (const s of PROFILES.core) {
assert.ok(result.skills.has(s), `core closure should include ${s}`);
}