Skip to content

Commit

Permalink
fix(server): resolve type errors
Browse files Browse the repository at this point in the history
  • Loading branch information
p-98 committed Jul 13, 2024
1 parent bfdf61b commit e6e34e7
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions server/__test__/guests.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,12 @@ async function testCreateGuest(
assert.isAtLeast(new Date(guest.enteredAt).getTime(), before.getTime());
assert.isAtMost(new Date(guest.enteredAt).getTime(), after.getTime());

const guestClient = await buildHTTPUserExecutor(knex, yoga, guest, {
noSeed: true,
});
const guestClient = await buildHTTPUserExecutor(
knex,
yoga,
{ ...guest, password: undefined },
{ noSeed: true }
);
await assertGuestState(guestClient)(guest);

return guest;
Expand Down Expand Up @@ -168,9 +171,12 @@ async function testLeaveGuest(guest: TGuest): Promise<void> {
assert.isAtLeast(new Date(left.leftAt!).getTime(), before.getTime());
assert.isAtMost(new Date(left.leftAt!).getTime(), after.getTime());

const guestClient = await buildHTTPUserExecutor(knex, yoga, guest, {
noSeed: true,
});
const guestClient = await buildHTTPUserExecutor(
knex,
yoga,
{ ...guest, password: undefined },
{ noSeed: true }
);
await assertGuestState(guestClient)(guest, [before, after]);
}

Expand Down

0 comments on commit e6e34e7

Please sign in to comment.