ci: trigga på master + formatfix inför Gitea Actions
CI / Typecheck, test & build (push) Failing after 2s

This commit is contained in:
Sven (AAMOS AI)
2026-08-13 17:25:14 +07:00
parent 61d60931ad
commit c32a7e33c7
141 changed files with 40555 additions and 45210 deletions
+15 -3
View File
@@ -4,7 +4,13 @@
*/
import { describe, expect, it, beforeAll, afterAll } from "vitest";
import { eq } from "drizzle-orm";
import { createDatabase, closeDatabase, schema, isAnalyticsOptedIn, deleteUserAnalyticsEvents } from "@app/database";
import {
createDatabase,
closeDatabase,
schema,
isAnalyticsOptedIn,
deleteUserAnalyticsEvents,
} from "@app/database";
const TEST_USER_EMAIL = "analytics-gdpr-test@example.invalid";
@@ -76,7 +82,11 @@ describe("analytics GDPR helpers", () => {
// Insert a dummy event for the test user and another user.
const [otherUser] = await db
.insert(schema.users)
.values({ email: "other-analytics-test@example.invalid", displayName: "Other", locale: "sv-SE" })
.values({
email: "other-analytics-test@example.invalid",
displayName: "Other",
locale: "sv-SE",
})
.returning({ id: schema.users.id });
await db.insert(schema.productAnalyticsEvents).values({
@@ -99,7 +109,9 @@ describe("analytics GDPR helpers", () => {
.where(eq(schema.productAnalyticsEvents.userId, otherUser!.id));
expect(remaining).toHaveLength(1);
await db.delete(schema.productAnalyticsEvents).where(eq(schema.productAnalyticsEvents.userId, otherUser!.id));
await db
.delete(schema.productAnalyticsEvents)
.where(eq(schema.productAnalyticsEvents.userId, otherUser!.id));
await db.delete(schema.users).where(eq(schema.users.id, otherUser!.id));
});
});