refactor(db): migrate to libsql

This commit is contained in:
Meier Lukas committed 2026-01-04 19:30:37 +01:00
1 parent 96e2f4fcca
commit 3fbc5013c3
52 files changed
+523 -1450

No files matched your search

+2 -2
View File
@@ -2,7 +2,7 @@ import type { StartedTestContainer } from "testcontainers";
import { GenericContainer, getContainerRuntimeClient, ImageName, Wait } from "testcontainers";
import { beforeAll, describe, expect, test, vi } from "vitest";
import { createDb } from "@homarr/db/test";
import { createDbAsync } from "@homarr/db/test";
import { Aria2Integration } from "../src";
@@ -11,7 +11,7 @@ vi.mock("@homarr/db", async (importActual) => {
const actual = await importActual<typeof import("@homarr/db")>();
return {
...actual,
db: createDb(),
db: await createDbAsync(),
};
});
vi.mock("@homarr/core/infrastructure/certificates", async (importActual) => {
+2 -2
View File
@@ -1,7 +1,7 @@
import { describe, expect, test, vi } from "vitest";
import { ResponseError } from "@homarr/common/server";
import { createDb } from "@homarr/db/test";
import { createDbAsync } from "@homarr/db/test";
import type { IntegrationTestingInput } from "../src/base/integration";
import { Integration } from "../src/base/integration";
@@ -12,7 +12,7 @@ vi.mock("@homarr/db", async (importActual) => {
const actual = await importActual<typeof import("@homarr/db")>();
return {
...actual,
db: createDb(),
db: await createDbAsync(),
};
});
@@ -3,7 +3,7 @@ import type { StartedTestContainer } from "testcontainers";
import { GenericContainer, getContainerRuntimeClient, ImageName, Wait } from "testcontainers";
import { beforeAll, describe, expect, test, vi } from "vitest";
import { createDb } from "@homarr/db/test";
import { createDbAsync } from "@homarr/db/test";
import { HomeAssistantIntegration } from "../src";
import { TestConnectionError } from "../src/base/test-connection/test-connection-error";
@@ -13,7 +13,7 @@ vi.mock("@homarr/db", async (importActual) => {
const actual = await importActual<typeof import("@homarr/db")>();
return {
...actual,
db: createDb(),
db: await createDbAsync(),
};
});
+2 -2
View File
@@ -4,7 +4,7 @@ import type { StartedTestContainer } from "testcontainers";
import { GenericContainer, getContainerRuntimeClient, ImageName, Wait } from "testcontainers";
import { beforeAll, describe, expect, test, vi } from "vitest";
import { createDb } from "@homarr/db/test";
import { createDbAsync } from "@homarr/db/test";
import { NzbGetIntegration } from "../src";
import { TestConnectionError } from "../src/base/test-connection/test-connection-error";
@@ -14,7 +14,7 @@ vi.mock("@homarr/db", async (importActual) => {
const actual = await importActual<typeof import("@homarr/db")>();
return {
...actual,
db: createDb(),
db: await createDbAsync(),
};
});
+2 -2
View File
@@ -2,7 +2,7 @@ import type { StartedTestContainer } from "testcontainers";
import { GenericContainer, Wait } from "testcontainers";
import { describe, expect, test, vi } from "vitest";
import { createDb } from "@homarr/db/test";
import { createDbAsync } from "@homarr/db/test";
import { PiHoleIntegrationV5, PiHoleIntegrationV6 } from "../src";
import type { SessionStore } from "../src/base/session-store";
@@ -13,7 +13,7 @@ vi.mock("@homarr/db", async (importActual) => {
const actual = await importActual<typeof import("@homarr/db")>();
return {
...actual,
db: createDb(),
db: await createDbAsync(),
};
});
+2 -2
View File
@@ -3,7 +3,7 @@ import { GenericContainer, getContainerRuntimeClient, ImageName, Wait } from "te
import type { StartedTestContainer } from "testcontainers";
import { beforeAll, describe, expect, test, vi } from "vitest";
import { createDb } from "@homarr/db/test";
import { createDbAsync } from "@homarr/db/test";
import { SabnzbdIntegration } from "../src";
import { TestConnectionError } from "../src/base/test-connection/test-connection-error";
@@ -14,7 +14,7 @@ vi.mock("@homarr/db", async (importActual) => {
const actual = await importActual<typeof import("@homarr/db")>();
return {
...actual,
db: createDb(),
db: await createDbAsync(),
};
});