Update Healer Man server

This commit is contained in:
phenom committed 2026-09-30 13:25:55 -04:00
1 parent 4fb7a0b9c8
commit 4c768fbec6
24 files changed
+654 -22

No files matched your search

+28
View File
@@ -10,6 +10,7 @@ import { beginMainMenuCharacterEditing } from "./mainMenuCharacterEditing";
import { selectedCharacter, useShellStore } from "./shellStore";
import { useCombatStore } from "../game/combatStore";
import { talentNodesForTree } from "../game/talentCatalog";
import { WOW335_GLYPH_OF_SWIFTMEND_ID } from "../game/wow335GlyphCatalog";
class MemoryStorage implements StorageLike {
values = new Map<string, string>();
@@ -65,6 +66,33 @@ describe("main-menu character editing", () => {
expect(listCharacters("offline-roster", storage)[0]).toMatchObject({ level: 17, experience: 123 });
});
it("persists a glyph toggle and reloads it when the editor is reopened", () => {
const druid = createCharacter({
ownerId: "offline-roster", name: "Leafkeeper", classId: "druid",
raceId: "night-elf", gender: "female", appearance: createDefaultAppearance(),
specializationId: "druid:restoration",
}, storage).character!;
useShellStore.setState({
selectedCharacterId: druid.id,
characters: [druid],
});
stop = beginMainMenuCharacterEditing(storage);
expect(useCombatStore.getState().glyphIds).not.toContain(WOW335_GLYPH_OF_SWIFTMEND_ID);
expect(useCombatStore.getState().classId).toBe("druid");
expect(useCombatStore.getState().setGlyphActive(WOW335_GLYPH_OF_SWIFTMEND_ID, true)).toBe(true);
expect(useCombatStore.getState().glyphIds).toEqual([WOW335_GLYPH_OF_SWIFTMEND_ID]);
expect(listCharacters("offline-roster", storage).find((character) => character.id === druid.id)?.glyphIds)
.toEqual([WOW335_GLYPH_OF_SWIFTMEND_ID]);
expect(selectedCharacter(useShellStore.getState())?.glyphIds).toEqual([WOW335_GLYPH_OF_SWIFTMEND_ID]);
stop!();
stop = beginMainMenuCharacterEditing(storage);
expect(useCombatStore.getState().glyphIds).toEqual([WOW335_GLYPH_OF_SWIFTMEND_ID]);
useCombatStore.getState().setGlyphActive(WOW335_GLYPH_OF_SWIFTMEND_ID, false);
expect(listCharacters("offline-roster", storage).find((character) => character.id === druid.id)?.glyphIds).toEqual([]);
});
it("persists controller assignments and reloads them without touching progression or equipment", () => {
const profile = selectedCharacter(useShellStore.getState())!;
stop = beginMainMenuCharacterEditing(storage);