Skip to content

Commit

Permalink
Fix backend test
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielHougaard committed Feb 22, 2024
1 parent da1fccc commit 995a81d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
1 change: 1 addition & 0 deletions backend/e2e-test/vitest-environment-knex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export default {
{ expiresIn: cfg.JWT_AUTH_LIFETIME }
);
} catch (error) {
console.log("[TEST] Error setting up environment", error);
await db.destroy();
throw error;
}
Expand Down
8 changes: 2 additions & 6 deletions backend/src/db/seeds/3-project.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,12 @@ export async function seed(knex: Knex): Promise<void> {
name: seedData1.project.name,
orgId: seedData1.organization.id,
slug: "first-project",
// @ts-expect-error exluded type id needs to be inserted here to keep it testable
// eslint-disable-next-line
// @ts-ignore
id: seedData1.project.id
})
.returning("*");

// await knex(TableName.ProjectKeys).insert({
// projectId: project.id,
// senderId: seedData1.id
// });

await knex(TableName.ProjectMembership).insert({
projectId: project.id,
role: OrgMembershipRole.Admin,
Expand Down

0 comments on commit 995a81d

Please sign in to comment.