chore: fix TS alias resolution and SVG mocking for test setup

This commit is contained in:
Ilia Mashkov
2026-04-22 09:45:51 +03:00
parent a60dbcfa51
commit 84ac886c33
2 changed files with 3 additions and 1 deletions
+2
View File
@@ -38,6 +38,8 @@
"src/**/*.js",
"src/**/*.svelte",
"src/**/*.d.ts",
"vitest.config*.ts",
"vitest.setup*.ts",
"vitest.types.d.ts"
],
"exclude": [
+1 -1
View File
@@ -17,7 +17,7 @@ Element.prototype.animate = vi.fn().mockReturnValue({
});
// jsdom lacks SVG geometry methods
SVGElement.prototype.getTotalLength = vi.fn(() => 0);
(SVGElement.prototype as any).getTotalLength = vi.fn(() => 0);
// Robust localStorage mock for jsdom environment
const localStorageMock = (() => {