chore: formated tests
Check Deno code / Check Deno code (pull_request) Successful in 5s
Tests / Unit tests (pull_request) Successful in 12s
Tests / Integration tests (pull_request) Successful in 1m9s
Check Deno code / Check Deno code (push) Successful in 6s
Tests / Unit tests (push) Successful in 12s
Tests / Integration tests (push) Successful in 1m13s

This commit was merged in pull request #145.
This commit is contained in:
2026-04-26 19:07:15 +02:00
parent b0930b8da2
commit 714486f43c
16 changed files with 699 additions and 176 deletions
+11 -3
View File
@@ -17,7 +17,10 @@ Deno.test({
async fn() {
await truncateAll();
await seedUes([{ nom: "UE Informatique" }, { nom: "UE Mathématiques" }]);
const res = await uesHandler.GET!(makeGetRequest("/ues"), makeEmployeeContext());
const res = await uesHandler.GET!(
makeGetRequest("/ues"),
makeEmployeeContext(),
);
assertEquals(res.status, 200);
const body = await res.json();
assertEquals(body.length, 2);
@@ -30,7 +33,10 @@ Deno.test({
name: "e2e ues: GET /ues returns empty when no UEs",
async fn() {
await truncateAll();
const res = await uesHandler.GET!(makeGetRequest("/ues"), makeEmployeeContext());
const res = await uesHandler.GET!(
makeGetRequest("/ues"),
makeEmployeeContext(),
);
assertEquals(res.status, 200);
const body = await res.json();
assertEquals(body.length, 0);
@@ -113,7 +119,9 @@ Deno.test({
await truncateAll();
const [ue] = await seedUes([{ nom: "UE Biologie" }]);
const res = await ueHandler.PUT!(
makeJsonRequest(`/ues/${ue.id}`, "PUT", { nom: "UE Biologie moléculaire" }),
makeJsonRequest(`/ues/${ue.id}`, "PUT", {
nom: "UE Biologie moléculaire",
}),
makeEmployeeContext({ idUE: String(ue.id) }),
);
assertEquals(res.status, 200);