chore: vitest remove globals

This commit is contained in:
Koen Kanters
2025-10-01 20:30:11 +02:00
parent ca489daad8
commit cf93c649aa
4 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
// biome-ignore assist/source/organizeImports: import mocks first
import {afterAll, beforeAll, beforeEach, describe, expect, it, vi} from "vitest";
import {afterAll, beforeAll, beforeEach, describe, expect, it, vi, assert} from "vitest";
import * as data from "../mocks/data";
import {mockLogger} from "../mocks/logger";
import {mockMQTTPublishAsync} from "../mocks/mqtt";
+1
View File
@@ -1,3 +1,4 @@
import {vi} from "vitest";
import utils from "../../lib/util/utils";
const spy = vi.spyOn(utils, "sleep");
+1
View File
@@ -1,3 +1,4 @@
import {vi} from "vitest";
import type {DefinitionWithExtend} from "zigbee-herdsman-converters";
export type EventHandler = (...args: unknown[]) => unknown;
-1
View File
@@ -3,7 +3,6 @@ import {defineConfig} from "vitest/config";
export default defineConfig({
plugins: [],
test: {
globals: true,
onConsoleLog(_log: string, _type: "stdout" | "stderr"): boolean | undefined {
return false;
},