From 8944b0908b5e264beacb41178a1a71270a56a68c Mon Sep 17 00:00:00 2001 From: Sam Rose Date: Wed, 20 Nov 2024 12:37:36 +0000 Subject: [PATCH] Create failing test in test-libraries --- .../backend-core/src/users/test/db.spec.ts | 21 +------------------ 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/packages/backend-core/src/users/test/db.spec.ts b/packages/backend-core/src/users/test/db.spec.ts index 3e29d6673c..a279fa3780 100644 --- a/packages/backend-core/src/users/test/db.spec.ts +++ b/packages/backend-core/src/users/test/db.spec.ts @@ -36,26 +36,7 @@ describe("UserDB", () => { describe("save", () => { describe("create", () => { it("creating a new user will persist it", async () => { - const email = generator.email({}) - const user: User = structures.users.user({ - email, - tenantId: config.getTenantId(), - }) - - await config.doInTenant(async () => { - const saveUserResponse = await db.save(user) - - const persistedUser = await db.getUserByEmail(email) - expect(persistedUser).toEqual({ - ...user, - _id: saveUserResponse._id, - _rev: expect.stringMatching(/^1-\w+/), - password: expect.not.stringMatching(user.password!), - status: UserStatus.ACTIVE, - createdAt: Date.now(), - updatedAt: new Date().toISOString(), - }) - }) + throw new Error("oh no") }) it("the same email cannot be used twice in the same tenant", async () => {