task 12 brief - xopherdeep/do-it-for-the-xp GitHub Wiki
Files:
- Modify:
src/app/SideMenu/XpSettings/components/PacksSettings.vue,MovingHouseModal.vue(the moving entry opens the project wizard on Moving Out, pre-filled) - Modify:
src/app/Console/MyPortal/HomeTown/HomeTown.ts(the Old House spot hides once a Moving Out project exists) - Delete:
src/lib/services/core/packs/movingTemple.ts,src/lib/services/core/packs/movingTemple/houseRecord.tsand their specs, once nothing imports them (houseRooms.tsandhousePlanner.tsstay) - Create:
tests/e2e/specs/project-tower.spec.js - Test:
tests/unit/movingOutPrefill.spec.ts
Interfaces:
- Consumes: Tasks 2, 4, 8, 9.
- Produces:
prefillMovingOut(answers: MovingAnswers | null, openMoveQuests: readonly Achievement[], heroes: readonly PackHero[]): ProjectDraft. - Step 1: Write the failing tests:
prefillMovingOuttakes the rooms from the last Moving House answers, turns each openmove-*quest into a custom chore on its phase (the pack's phase from its categorycat-move-<phase>;campandunpackquests left out) and keeps its assignee; starting the Moving Out project removes thegen-move-housetemple record and keeps its paid quests' log; the Old House spot is hidden when the active or last project is Moving Out. - Step 2: Run
chemx test tests/unit/movingOutPrefill.spec.ts. Expected: FAIL. - Step 3: Implement, then remove
buildMovingTemple,movingTempleBackupandhouseRecord.tswith their specs oncechemx q -g "buildMovingTemple"finds no importer. - Step 4: Run the spec and
tests/unit/movingPack.spec.ts. Expected: PASS. - Step 5: Write the e2e walk
tests/e2e/specs/project-tower.spec.js(390x844,cy.seedWorld(),cy.tapToWakeAudio()): the GM starts Spring Cleaning with two rooms and the suggested chores; a hero claims every 1F chore throughwindow.__xp; the header shows the ×2 offer and "Floor cleared!"; the hero climbs to 2F; the test fast-forwards by claiming the rest; the roof's victory plays the credits ("Xopher Pollard aka XP" visible) and the trophy shows in Hometown. Run against the shared dev server only ifcurl -s localhost:8100answers from this worktree's files, else on the worktree's own port:pnpm vue-cli-service test:e2e --headless --browser chrome --url http://localhost:<port> --spec tests/e2e/specs/project-tower.spec.js. Expected: all passing. - Step 6: Lead commits
feat(projects): Moving Out replaces the Old House; the project tower walk.
-
chemx typecheckandchemx lint(no errors), then push the branch, open the PR, and turn on auto-merge (gh pr merge <n> --auto --squash); the PR's Tests check is the full gate.