import { beforeEach, describe, it } from "vitest"; import supertest from "supertest"; import app from "../main.js"; const request = supertest(app); describe.concurrent("Root handlers tests", async function() { describe.concurrent("When not logged in", async function() { it("/", async function() { request.get("/").expect("Content-Type", /text\/plain/).expect(302, /Redirecting to \/login$/); }); it("/login", async function() { request.get("/login").expect("Content-Type", /text\/html/).expect(200, /