From 0dd79161a64269a0521f96633547b96dd382b4b9 Mon Sep 17 00:00:00 2001 From: wolfganggreschus Date: Wed, 11 Dec 2024 08:37:42 +0100 Subject: [PATCH] Refactor board deletion confirmation steps and update visibility assertions in room feature tests --- cypress/e2e/room/createEditDeleteBoardInRoom.feature | 10 ++++++++-- cypress/support/step_definition/room/roomSteps.spec.js | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/cypress/e2e/room/createEditDeleteBoardInRoom.feature b/cypress/e2e/room/createEditDeleteBoardInRoom.feature index aab48fdf..781db206 100644 --- a/cypress/e2e/room/createEditDeleteBoardInRoom.feature +++ b/cypress/e2e/room/createEditDeleteBoardInRoom.feature @@ -29,7 +29,6 @@ Feature: Room - Add, edit and delete board in room Then I enter the course board title '' When I click on the page outside of the title of the board Then I see my room board is named '' - # TODO test if renaming worked # cancel delete-process When I click on the button three dot menu in room board @@ -38,12 +37,19 @@ Feature: Room - Add, edit and delete board in room When I click on the button to cancel the deletion Then I see the page room board details Then I see the board '' on the room overview page + + # confirm delete-process When I click on the button three dot menu in room board When I click on delete in board menu Then I see the button to cancel the dialog Then I click on the button to confirm the deletion - Then I do not see the board '' on the room overview page + Then I do not see the board '' in the room + # post-condition: delete room + When I click on three dot menu in room page + When I click on delete option in room menu + Then I see confirmation modal for deleting the room + When I click on delete button in confirmation modal diff --git a/cypress/support/step_definition/room/roomSteps.spec.js b/cypress/support/step_definition/room/roomSteps.spec.js index d34c92bd..973a6601 100644 --- a/cypress/support/step_definition/room/roomSteps.spec.js +++ b/cypress/support/step_definition/room/roomSteps.spec.js @@ -188,7 +188,7 @@ Then("I see the button to confirm the dialog", () => { When("I click on the button to confirm the deletion", () => { rooms.clickBtnDialogConfirmDelete(); }); -Then("I do not see the board {string} on the room overview page", (boardTitle) => { +Then("I do not see the board {string} in the room", (boardTitle) => { rooms.boardIsNotVisibleOnOverviewPage(boardTitle); });