forked from phenom/healer-man
16 lines
667 B
TypeScript
16 lines
667 B
TypeScript
import { describe, expect, it } from "vitest";
|
|
import { actorEnteredManastormPortal } from "./manastorm";
|
|
import { playerEnteredManastormPortal } from "./manastormPortalActivation";
|
|
|
|
describe("Manastorm portal activation", () => {
|
|
it("does not advance when only a companion is inside the portal", () => {
|
|
const portal = [10, 4, 10] as const;
|
|
const player = [30, 4, 10] as const;
|
|
const companion = [11, 4, 10] as const;
|
|
|
|
expect(actorEnteredManastormPortal(portal, [player, companion])).toBe(true);
|
|
expect(playerEnteredManastormPortal(portal, player)).toBe(false);
|
|
expect(playerEnteredManastormPortal(portal, companion)).toBe(true);
|
|
});
|
|
});
|