formatting

This commit is contained in:
lila 2026-04-30 01:20:12 +02:00
parent 35e54014b3
commit 4f47e18ad9
7 changed files with 119 additions and 124 deletions

View file

@ -27,7 +27,7 @@ export function createApp() {
const store = new InMemoryGameSessionStore();
app.use("/api/v1", createApiRouter(store));
app.use(errorHandler);
return app;

View file

@ -197,7 +197,7 @@ describe("POST /api/v1/game/answer", () => {
expect(body.success).toBe(false);
expect(body.error).toContain("Question already answered");
});
it("returns 400 when a field has an invalid value", async () => {
const res = await request(app)
.post("/api/v1/game/start")

View file

@ -30,4 +30,4 @@ export class UnprocessableEntityError extends AppError {
constructor(message: string) {
super(message, 422);
}
}
}

View file

@ -14,6 +14,6 @@ export const createGameRouter = (store: GameSessionStore): Router => {
router.post("/start", controller.createGame as express.RequestHandler);
router.post("/answer", controller.submitAnswer as express.RequestHandler);
return router;
};