Fix workflow gitea action pour e2e (tests automatisés via playwright) + correction d'une incohérence dans l'API coté java. Ajout d'autres tests utilisateur

This commit is contained in:
2026-04-25 00:45:04 +02:00
parent 2a438b79ce
commit f6b4e3ff82
17 changed files with 327 additions and 51 deletions

View File

@@ -79,7 +79,7 @@ class ArcControllerTest {
@Test
void getByCampaign_pathVariant() throws Exception {
arcRepository.save(Arc.builder().campaignId(campaignId).name("A").order(0).build());
mockMvc.perform(get("/api/arcs/campaign/{id}", campaignId))
mockMvc.perform(get("/api/arcs").param("campaignId", campaignId))
.andExpect(status().isOk())
.andExpect(jsonPath("$").isArray());
}

View File

@@ -81,7 +81,7 @@ class ChapterControllerTest {
@Test
void getByArc_pathVariant() throws Exception {
chapterRepository.save(Chapter.builder().arcId(arcId).name("A").order(0).build());
mockMvc.perform(get("/api/chapters/arc/{id}", arcId))
mockMvc.perform(get("/api/chapters").param("arcId", arcId))
.andExpect(status().isOk())
.andExpect(jsonPath("$").isArray());
}

View File

@@ -85,7 +85,7 @@ class SceneControllerTest {
@Test
void getByChapter_pathVariant() throws Exception {
sceneRepository.save(Scene.builder().chapterId(chapterId).name("A").order(0).build());
mockMvc.perform(get("/api/scenes/chapter/{id}", chapterId))
mockMvc.perform(get("/api/scenes").param("chapterId", chapterId))
.andExpect(status().isOk())
.andExpect(jsonPath("$").isArray());
}