update prettier config

This commit is contained in:
m5r
2021-08-01 20:04:04 +08:00
parent fdf9df243b
commit 7acbca65ce
33 changed files with 65 additions and 52 deletions

View File

@ -20,5 +20,5 @@ export default resolver.pipe(
});
return true;
}
},
);

View File

@ -18,7 +18,7 @@ jest.mock("preview-email", () => jest.fn());
describe.skip("forgotPassword mutation", () => {
it("does not throw error if user doesn't exist", async () => {
await expect(
forgotPassword({ email: "no-user@email.com" }, {} as Ctx)
forgotPassword({ email: "no-user@email.com" }, {} as Ctx),
).resolves.not.toThrow();
});

View File

@ -53,21 +53,21 @@ describe.skip("resetPassword mutation", () => {
// Non-existent token
await expect(
resetPassword({ token: "no-token", password: "", passwordConfirmation: "" }, mockCtx)
resetPassword({ token: "no-token", password: "", passwordConfirmation: "" }, mockCtx),
).rejects.toThrowError();
// Expired token
await expect(
resetPassword(
{ token: expiredToken, password: newPassword, passwordConfirmation: newPassword },
mockCtx
)
mockCtx,
),
).rejects.toThrowError();
// Good token
await resetPassword(
{ token: goodToken, password: newPassword, passwordConfirmation: newPassword },
mockCtx
mockCtx,
);
// Delete's the token
@ -77,7 +77,7 @@ describe.skip("resetPassword mutation", () => {
// Updates user's password
const updatedUser = await db.user.findFirst({ where: { id: user.id } });
expect(await SecurePassword.verify(updatedUser!.hashedPassword, newPassword)).toBe(
SecurePassword.VALID
SecurePassword.VALID,
);
});
});