mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-05-28 18:26:54 +00:00
chore(api): add ExamEnvironmentAuthorizationToken -> user relation (#56627)
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
This commit is contained in:
@@ -207,6 +207,11 @@ export const defaultUserEmail = 'foo@bar.com';
|
||||
export const defaultUsername = 'fcc-test-user';
|
||||
|
||||
export const resetDefaultUser = async (): Promise<void> => {
|
||||
await fastifyTestInstance.prisma.examEnvironmentAuthorizationToken.deleteMany(
|
||||
{
|
||||
where: { userId: defaultUserId }
|
||||
}
|
||||
);
|
||||
await fastifyTestInstance.prisma.user.deleteMany({
|
||||
where: { email: defaultUserEmail }
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user