fix: Fix biome correctness errors

This commit is contained in:
2026-03-23 08:32:30 +05:30
parent 7a164c705c
commit 36c6700437
8 changed files with 24 additions and 40 deletions
+4 -5
View File
@@ -7,7 +7,6 @@ import {
spyOn,
test,
} from "bun:test";
import * as fs from "node:fs";
import * as os from "node:os";
import {
createWindowBaseName,
@@ -36,7 +35,7 @@ let mockCommandResponses: Record<
let executedCommands: string[] = [];
function setupMockBun$() {
const mockFn = mock((strings: TemplateStringsArray, ...values: any[]) => {
const mockFn = mock((_strings: TemplateStringsArray, ...values: any[]) => {
const parts = values[0] as string[];
const commandSignature = parts.join(" ");
executedCommands.push(commandSignature);
@@ -66,11 +65,11 @@ function restoreOriginalBun$() {
}
describe("core utils", () => {
let bunMock: ReturnType<typeof setupMockBun$>;
let _bunMock: ReturnType<typeof setupMockBun$>;
beforeEach(() => {
spyOn(os, "homedir").mockReturnValue("/mock/home");
bunMock = setupMockBun$();
_bunMock = setupMockBun$();
executedCommands = [];
mockCommandResponses = {};
});
@@ -282,7 +281,7 @@ describe("core utils", () => {
expect(result.stderr).toBe("");
});
test("returns ok false for failed command", async () => {
mockCommandResponses["false"] = {
mockCommandResponses.false = {
ok: false,
stdout: "",
stderr: "error",