From 0c9f00d9a8e2bbc9596eab5ce380cd3541ba0a23 Mon Sep 17 00:00:00 2001 From: Bastian Wagner Date: Fri, 21 Aug 2026 18:28:52 +0200 Subject: [PATCH] fix(web): finish the reward-preview sweep the seed change started When I dropped Silber and Erfahrung from the burned road's seeded reward preview (e5752c7, because R7 zeroed every monster's silver on that road), I updated the server content but not the web fixture that mirrors it. burnedRoadFixture() still advertised Silber, and the sidebar spec still asserted it rendered -- so the web tests were proving the UI shows a category the API no longer sends. Also clears dead level/experience fixture fields and an experience key in a reward-service mock from combat-equipment-integration.spec.ts. They were inert (nothing read them) but they date from after the API-side sweep and describe fields the entity and DTO no longer have. API 267/267, web 229/229. Co-Authored-By: Claude Opus 5 --- apps/api/src/combat/combat-equipment-integration.spec.ts | 4 +--- apps/web/src/app/features/world/current-location.fixture.ts | 1 - .../world/location-sidebar/location-sidebar.component.spec.ts | 1 - 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/apps/api/src/combat/combat-equipment-integration.spec.ts b/apps/api/src/combat/combat-equipment-integration.spec.ts index e0fa3c4..874f7e4 100644 --- a/apps/api/src/combat/combat-equipment-integration.spec.ts +++ b/apps/api/src/combat/combat-equipment-integration.spec.ts @@ -190,8 +190,6 @@ function character(overrides: Partial = {}): Character { return { id: CHARACTER_ID, name: 'Aric Duskwalker', - level: 1, - experience: 0, silver: 0, baseHp: 100, baseAttack: 6, @@ -283,7 +281,7 @@ function fakeRewardService(): CombatRewardService { return { grantVictoryRewards: jest .fn() - .mockResolvedValue({ experience: 0, silver: 0, items: [] }), + .mockResolvedValue({ silver: 0, items: [] }), loadRewards: jest.fn().mockResolvedValue(null), } as unknown as CombatRewardService; } diff --git a/apps/web/src/app/features/world/current-location.fixture.ts b/apps/web/src/app/features/world/current-location.fixture.ts index 7f9a532..85db7ad 100644 --- a/apps/web/src/app/features/world/current-location.fixture.ts +++ b/apps/web/src/app/features/world/current-location.fixture.ts @@ -170,7 +170,6 @@ export function burnedRoadFixture( }, ], rewardPreview: [ - { key: 'silver', label: 'Silber', iconKey: 'silver' }, { key: 'equipment', label: 'Ausrüstung', iconKey: 'equipment' }, { key: 'material', label: 'Material', iconKey: 'material' }, ], diff --git a/apps/web/src/app/features/world/location-sidebar/location-sidebar.component.spec.ts b/apps/web/src/app/features/world/location-sidebar/location-sidebar.component.spec.ts index 433dc70..2448906 100644 --- a/apps/web/src/app/features/world/location-sidebar/location-sidebar.component.spec.ts +++ b/apps/web/src/app/features/world/location-sidebar/location-sidebar.component.spec.ts @@ -81,7 +81,6 @@ describe('LocationSidebarComponent', () => { const rewards = element.querySelectorAll('[data-sidebar="rewards"] li'); expect([...rewards].map((item) => item.textContent?.trim())).toEqual([ - 'Silber', 'Ausrüstung', 'Material', ]);