diff --git a/spec/rolls/check-evaluation.spec.ts b/spec/rolls/check-evaluation.spec.ts index f0c829a1..be26d9c6 100644 --- a/spec/rolls/check-evaluation.spec.ts +++ b/spec/rolls/check-evaluation.spec.ts @@ -5,7 +5,23 @@ import evaluateCheck from "../../src/module/rolls/check-evaluation"; -Object.defineProperty(globalThis, "game", { value: { i18n: { localize: (key: string) => key } } }); +class StubGame { + constructor() { + this.i18n = { + localize: (a: string) => a, + }; + } + i18n: { + localize: (a: string) => string; + }; +} + +const game = new StubGame(); + +Object.defineProperties(globalThis, { + game: { value: game }, + Game: { value: StubGame }, +}); describe("evaluateCheck with no dice", () => { it("should throw an error.", () => {