test(shared): update shared utility tests

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
YeonGyu-Kim
2026-04-10 15:53:37 +09:00
parent 37057f18b9
commit e7f5d0d5fd
4 changed files with 57 additions and 23 deletions
@@ -2,7 +2,6 @@
import { afterAll, afterEach, beforeEach, describe, expect, it, mock, spyOn } from "bun:test"
import type { LegacyPluginCheckResult } from "./legacy-plugin-warning"
import { logLegacyPluginStartupWarning } from "./log-legacy-plugin-startup-warning"
function createLegacyPluginCheckResult(
overrides: Partial<LegacyPluginCheckResult> = {},
@@ -26,8 +25,7 @@ afterAll(() => {
})
async function importFreshStartupWarningModule(): Promise<typeof import("./log-legacy-plugin-startup-warning")> {
consoleWarnSpy = spyOn(console, "warn").mockImplementation(() => {})
return { logLegacyPluginStartupWarning }
return import(`./log-legacy-plugin-startup-warning?test=${Date.now()}-${Math.random()}`)
}
describe("logLegacyPluginStartupWarning", () => {