fix: dockview, sprite, auth, and CLI db backup improvements (#1075)

This commit is contained in:
Carlos Florêncio
2026-05-28 16:23:17 +01:00
committed by GitHub
parent 905b9f9727
commit f4be0d279c
42 changed files with 1943 additions and 318 deletions
+9
View File
@@ -137,6 +137,15 @@ describe("resolveRuntime", () => {
describe("no runtime found", () => {
it("throws an actionable error message mentioning install paths", () => {
// Ensure require.resolve fails so we reach the "no runtime found" path.
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const ModuleAny = Module as unknown as { _resolveFilename: any };
vi.spyOn(ModuleAny, "_resolveFilename").mockImplementationOnce(() => {
const err = new Error("Cannot find module") as Error & { code: string };
err.code = "MODULE_NOT_FOUND";
throw err;
});
let error: Error | null = null;
try {
resolveRuntime();