Fix oxlint warnings, extract dialog polyfill, deny warnings in gate
All checks were successful
CI / check (push) Successful in 1m38s
CI / build-image (push) Has been skipped

Adds void to floating promise in bestiary-cache.ts, extracts shared
polyfillDialog() helper to eliminate unbound-method warnings in 3 test
files. Adds --deny warnings to oxlint so future warnings fail the
build.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Lukas
2026-03-29 22:38:57 +02:00
parent c295840b7b
commit b6ee4c8c86
7 changed files with 26 additions and 34 deletions

View File

@@ -4,19 +4,11 @@ import { playerCharacterId } from "@initiative/domain";
import { cleanup, render, screen } from "@testing-library/react";
import { userEvent } from "@testing-library/user-event";
import { afterEach, beforeAll, describe, expect, it, vi } from "vitest";
import { polyfillDialog } from "../../__tests__/polyfill-dialog.js";
import { CreatePlayerModal } from "../create-player-modal.js";
beforeAll(() => {
HTMLDialogElement.prototype.showModal =
HTMLDialogElement.prototype.showModal ||
function showModal(this: HTMLDialogElement) {
this.setAttribute("open", "");
};
HTMLDialogElement.prototype.close =
HTMLDialogElement.prototype.close ||
function close(this: HTMLDialogElement) {
this.removeAttribute("open");
};
polyfillDialog();
});
afterEach(cleanup);