Driver
test_split_portfolio_v2_migration.sh Case 1 uses a SINGLE workspace project (demo). The migration spec already handles multi-project edge cases — specifically the "project already exists in sibling — skip with warning, don't overwrite" path documented in the SKILL.md:
if [ -e "$SIBLING_ROOT/workspace/$name" ]; then
echo "WARNING: workspace/$name exists in BOTH locations — skipped."
continue
fi
That conflict-skip path is not exercised by any test today. If a future change to the loop or the conflict-check breaks the skip-and-warn behaviour (e.g. removes the continue, swallows the warning, accidentally overwrites the sibling copy), nothing catches it until an adopter hits the real-world case.
Also unexercised: the workspace/README.md skip — the framework artefact must stay in the public fork during the move, per AgDR-0021 § G. Currently relies on operator reading the spec; not test-pinned.
The 4-gap audit (2026-05-20) identified this as Gap 4 of 4 (lowest priority).
Scope
- Extend
.claude/hooks/tests/test_split_portfolio_v2_migration.sh with a new case (Case 4 — or fold into Case 1 if cleaner):
- Multi-project workspace — sandbox has 3+ projects in
workspace/<name>/ (e.g. alpha, beta, gamma)
- Mixed presence — pre-create
workspace/beta in the sibling private repo before running migration (the conflict-skip path)
- README.md framework artefact —
workspace/README.md exists in the public fork (it's the framework's docs file for the convention)
- Assertions:
- All 3 projects end up in the sibling's
workspace/ (alpha + beta + gamma)
beta is NOT overwritten (sibling pre-existing content preserved)
- Conflict-skip warning prints to stderr (
grep "WARNING.*beta.*BOTH locations" stderr)
- Migration doesn't abort on the conflict — it continues to gamma
workspace/README.md stays in the public fork (framework artefact preserved)
- All other v2 assertions from Case 1 still hold (marker, gitignore, config keys)
- All existing 3 cases still pass (no regression)
Acceptance Criteria
Cross-reference with T1: T1 changes onboarding.yaml from mv to cp. The workspace/ migration STAYS mv (size constraint). The Case 4 assertions only touch workspace/ semantics so T1's changes don't conflict.
Refs #312 (audit findings — Gap 4 of 4 from /update + /setup audit on 2026-05-20)
Driver
test_split_portfolio_v2_migration.shCase 1 uses a SINGLE workspace project (demo). The migration spec already handles multi-project edge cases — specifically the "project already exists in sibling — skip with warning, don't overwrite" path documented in the SKILL.md:That conflict-skip path is not exercised by any test today. If a future change to the loop or the conflict-check breaks the skip-and-warn behaviour (e.g. removes the
continue, swallows the warning, accidentally overwrites the sibling copy), nothing catches it until an adopter hits the real-world case.Also unexercised: the
workspace/README.mdskip — the framework artefact must stay in the public fork during the move, perAgDR-0021§ G. Currently relies on operator reading the spec; not test-pinned.The 4-gap audit (2026-05-20) identified this as Gap 4 of 4 (lowest priority).
Scope
.claude/hooks/tests/test_split_portfolio_v2_migration.shwith a new case (Case 4 — or fold into Case 1 if cleaner):workspace/<name>/(e.g.alpha,beta,gamma)workspace/betain the sibling private repo before running migration (the conflict-skip path)workspace/README.mdexists in the public fork (it's the framework's docs file for the convention)workspace/(alpha + beta + gamma)betais NOT overwritten (sibling pre-existing content preserved)grep "WARNING.*beta.*BOTH locations" stderr)workspace/README.mdstays in the public fork (framework artefact preserved)Acceptance Criteria
test_split_portfolio_v2_migration.shworkspace/README.mdstays in the public fork (framework artefact)Cross-reference with T1: T1 changes
onboarding.yamlfrommvtocp. Theworkspace/migration STAYSmv(size constraint). The Case 4 assertions only touchworkspace/semantics so T1's changes don't conflict.Refs #312 (audit findings — Gap 4 of 4 from
/update+/setupaudit on 2026-05-20)