diff --git a/cypress/e2e/admin/administrateCtlTools.feature b/cypress/e2e/admin/administrateCtlTools.feature index a4525c84..beba09a6 100644 --- a/cypress/e2e/admin/administrateCtlTools.feature +++ b/cypress/e2e/admin/administrateCtlTools.feature @@ -1,11 +1,14 @@ -@unstable_test -Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin +@regression_test +@stable_test +Feature: Admin adds, edits and deletes CTL tools in school As an admin I want to administrate the CTL tools used in the school - @unstable_test - Scenario: Admin adds, edits and deletes external tools - Given I am logged in as a 'admin1_nbc' at 'nbc' + @stable_test + Scenario Outline: Admin adds, edits and deletes external tools + Given I am logged in as a '' at '' + + # Admin tries to find a hidden external tool When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel @@ -14,16 +17,15 @@ Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin Then I see the external tools configuration page Then I see the external tool configuration page title Then I see the tool configuration infotext - # Admin tries to find a hidden external tool Then I do not see external tool 'CY Test Tool Hidden' in the tool selection - # Admin adds a tool + # Admin adds a tool When I select the tool 'CY Test Tool 1' from available tools Then I see tool 'CY Test Tool 1' is selected When I click on save external tool button Then I see the tool 'CY Test Tool 1' in external tools table - # Admin adds a tool with required custom parameter + # Admin adds a tool with required custom parameter When I click the add external tool button Then I see the external tools configuration page Then I see the external tool configuration page title @@ -35,17 +37,17 @@ Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin When I click on save external tool button Then I see the tool 'CY Test Tool Required Parameters' in external tools table - # Admin adds a tool via tool link with parameter + # Admin adds a tool via tool link with parameter When I click the add external tool button Then I see the external tools configuration page Then I see the external tool configuration page title Then I see the tool configuration infotext When I insert the external tool link 'https://www.openstreetmap.org/?mlat=52.40847&mlon=9.80823&zoom=19#map=19/52.40847/9.80823' - Then I see tool 'OpenStreetMap' is selected + Then I see tool 'CY Test Tool OpenStreetMap' is selected When I click on save external tool button - Then I see the tool 'OpenStreetMap' in external tools table + Then I see the tool 'CY Test Tool OpenStreetMap' in external tools table - # Admin adds a tool with optional custom parameter + # Admin adds a tool with optional custom parameter When I click the add external tool button Then I see the external tools configuration page Then I see the external tool configuration page title @@ -57,7 +59,7 @@ Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin When I click on save external tool button Then I see the tool 'CY Test Tool Optional Parameters' in external tools table - # Admin edits a tool + # Admin edits a tool When I click on edit button of tool 'CY Test Tool Optional Parameters' Then I see the external tools configuration page Then I see the external tool configuration page title @@ -71,7 +73,7 @@ Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin Then I see the external tools configuration page Then I see custom parameter input field 'schoolParam' contains 'updated test' - # Admin deletes tools + # Admin deletes tools When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel @@ -79,6 +81,7 @@ Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin Then I see the tool 'CY Test Tool 1' in external tools table Then I see the tool 'CY Test Tool Required Parameters' in external tools table Then I see the tool 'CY Test Tool Optional Parameters' in external tools table + Then I see the tool 'CY Test Tool OpenStreetMap' in external tools table When I click on delete button of tool 'CY Test Tool 1' Then I see the external tool deletion dialog title Then I see the external tool deletion dialog information text @@ -93,9 +96,18 @@ Feature: Admin CTL Tools - To add, edit and delete CTL tools by the admin Then I see the external tool deletion dialog title Then I see the external tool deletion dialog information text When I confirm deletion on deletion dialog - When I click on delete button of tool 'OpenStreetMap' + Then I do not see the tool 'CY Test Tool Optional Parameters' in external tools table + When I click on delete button of tool 'CY Test Tool OpenStreetMap' Then I see the external tool deletion dialog title Then I see the external tool deletion dialog information text When I confirm deletion on deletion dialog - Then I do not see the tool 'OpenStreetMap' in external tools table + Then I do not see the tool 'CY Test Tool OpenStreetMap' in external tools table Then I see the external tools table is empty + + @staging_test + Examples: + | admin | namespace | + | admin1_nbc | nbc | + + # @school_api_test + # This feature is not executable with the school_api \ No newline at end of file diff --git a/cypress/e2e/course/addEditDeleteCtlToolInCourse.feature b/cypress/e2e/course/addEditDeleteCtlToolInCourse.feature index 68245be8..e41db029 100644 --- a/cypress/e2e/course/addEditDeleteCtlToolInCourse.feature +++ b/cypress/e2e/course/addEditDeleteCtlToolInCourse.feature @@ -40,7 +40,6 @@ Feature: Course - To add, edit and delete a ctl tool in a course When I select the tool 'CY Test Tool Optional Parameters' from available tools When I click on save external tool button Then I see the tool 'CY Test Tool Optional Parameters' in external tools table - # Pre-condition: Admin adds tools via tool link When I click on administration in menu When I navigate to new school admin page via sub menu @@ -69,14 +68,12 @@ Feature: Course - To add, edit and delete a ctl tool in a course When I lauch tool 'CY Test Tool 1' with given url 'https://google.com/' Then I see tool 'CY Test Tool 1' was launched - # Teacher adds a tool twice with different name + # Teacher adds a tool twice but with a different name When I click on the button to add a tool Then I see the tool configuration page title When I click on the tool configuration selection When I select the tool 'CY Test Tool 1' from available tools Then I see tool 'CY Test Tool 1' is selected - When I click on save external tool button - Then I see an error alert When I enter 'CY Test Tool 1 New' in display name field When I click on save external tool button Then I see the tool 'CY Test Tool 1 New' in the tool overview @@ -173,12 +170,17 @@ Feature: Course - To add, edit and delete a ctl tool in a course Then I see the external tools table When I click on delete button of tool 'CY Test Tool 1' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table When I click on delete button of tool 'CY Test Tool Required Parameters' When I confirm deletion on deletion dialog + Then I do not see the tool 'Y Test Tool Required Parameters' in external tools table When I click on delete button of tool 'CY Test Tool Optional Parameters' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Optional Parameters' in external tools table When I click on delete button of tool 'CY Test Tool OpenStreetMap' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool OpenStreetMap' in external tools table + Then I see the external tools table is empty @staging_test Examples: diff --git a/cypress/e2e/course/contextRestrictionOfCtlTools.feature b/cypress/e2e/course/contextRestrictionOfCtlTools.feature deleted file mode 100644 index 4cd8f2c5..00000000 --- a/cypress/e2e/course/contextRestrictionOfCtlTools.feature +++ /dev/null @@ -1,188 +0,0 @@ -@unstable_test -Feature: Course - Restrict CTL tools to context course, board-element, media-board - - As a teacher I want add ctl tools with a certain context restriction - - @unstable_test - Scenario: Admin creates a course and adds external tools to school - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I go to courses overview - # Pre-Test: Admin creates a course - When I click on FAB to create a new course depending on sub menu - Then I see section one area on the course create page - When I enter the course title 'Cypress Test Course' - When I select 'Karl Herzog' from field teacher - When I click on button Next Steps after entering the course detail in section one - Then I see section two area on the course create page - When I click on button Next Steps after selecting course participant details - Then I see the section three area as the finish page - When I click on button To Course Overview on the finish page - # Admin adds tools - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - When I click the add external tool button - When I select the tool 'CY Test Tool 1' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in external tools table - Then I see the tool 'CY Test Tool 1' in external tools table has no context restriction - When I click the add external tool button - When I select the tool 'CY Test Tool Course Restriction' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Course Restriction' in external tools table - Then I see the tool 'CY Test Tool Course Restriction' in external tools table has context restriction 'Kurs-Tools' - When I click the add external tool button - When I select the tool 'CY Test Tool Board-Element Restriction' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table - Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table has context restriction 'Bereiche' - When I click the add external tool button - When I select the tool 'CY Test Tool Media-Board Restriction' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table - Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table has context restriction 'Medienregal' - When I click the add external tool button - When I select the tool 'CY Test Tool All Restrictions' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool All Restrictions' in external tools table - Then I see the tool 'CY Test Tool All Restrictions' in external tools table has context restriction 'Kurs-Tools, Bereiche, Medienregal' - When I click the add external tool button - When I select the tool 'CY Test Tool Preferred Course Restriction' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Preferred Course Restriction' in external tools table - Then I see the tool 'CY Test Tool Preferred Course Restriction' in external tools table has context restriction 'Kurs-Tools' - When I click the add external tool button - When I select the tool 'CY Test Tool Preferred Board Restriction' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Preferred Board Restriction' in external tools table - Then I see the tool 'CY Test Tool Preferred Board Restriction' in external tools table has context restriction 'Bereiche' - - @unstable_test - Scenario: Teacher adds ctl tools to context course, board-element and media-board - Given I am logged in as a 'teacher1_nbc' at 'nbc' - When I go to courses overview - When I go to course 'Cypress Test Course' - Then I see course page 'Cypress Test Course' - When I click on the tools tab - Then I see the button to add a tool - When I click on the button to add a tool - Then I see the tool configuration page title - When I click on the tool configuration selection - # Teacher tries to a tool with context restriction board-element - Then I do not see tool 'CY Test Tool Board-Element Restriction' in the tool selection - # Teacher tries to a tool with context restriction media-board - Then I do not see tool 'CY Test Tool Media-Board Restriction' in the tool selection - # Teacher adds a tool with context restriction course - When I select the tool 'CY Test Tool Course Restriction' from available tools - Then I see tool 'CY Test Tool Course Restriction' is selected - When I click on save external tool button - Then I see the tool 'CY Test Tool Course Restriction' in the tool overview - # Teacher adds a tool with all context restrictions - When I click on the button to add a tool - Then I see the tool configuration page title - When I click on the tool configuration selection - When I select the tool 'CY Test Tool All Restrictions' from available tools - Then I see tool 'CY Test Tool All Restrictions' is selected - When I click on save external tool button - Then I see the tool 'CY Test Tool All Restrictions' in the tool overview - # Teacher adds a tool without any context restriction - When I click on the button to add a tool - Then I see the tool configuration page title - When I click on the tool configuration selection - When I select the tool 'CY Test Tool 1' from available tools - Then I see tool 'CY Test Tool 1' is selected - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in the tool overview - - # Teacher adds ctl tools with context restriction board-element to a board - When I go to courses overview - When I go to course 'Cypress Test Course' - When I go to the tab contents in course detail page - When I click on FAB to create new content - When I click on the button FAB New Column Board - Then I see a dialog box for column board - Then I see in dialog box option for multi-column board - Then I see in dialog box option for single column board - When I choose multi-column board in the dialog box - Then I see the page Course Board details - Then I see the chip Draft in the course board - When I click on the button Add column in the course board - When I click on the page outside of the column - When I click on plus icon to add card in column - When I click on plus icon to add content into card - When I select external tools from the menu - When I click on the tool configuration selection - # Teacher tries to add a tool with context restriction course - Then I do not see tool 'CY Test Tool Course Restriction' in the tool selection - # Teacher tries to add a tool with context restriction media-board - Then I do not see tool 'CY Test Tool Media-Board Restriction' in the tool selection - # Teacher adds a tool with context restriction board-element - When I select the tool 'CY Test Tool Board-Element Restriction' from available tools - Then I see tool 'CY Test Tool Board-Element Restriction' is selected - When I click on save external tool button - Then I see an external tool element with tool 'CY Test Tool Board-Element Restriction' - # Teacher adds a tool with all context restrictions - When I click on plus icon to add card in column - When I click on plus icon to add content into card - When I select external tools from the menu - When I select the tool 'CY Test Tool All Restrictions' from available tools - Then I see tool 'CY Test Tool All Restrictions' is selected - When I click on save external tool button - Then I see an external tool element with tool 'CY Test Tool All Restrictions' - # Teacher adds a tool without any context restriction - When I click on plus icon to add card in column - When I click on plus icon to add content into card - When I select external tools from the menu - When I select the tool 'CY Test Tool 1' from available tools - Then I see tool 'CY Test Tool 1' is selected - When I click on save external tool button - Then I see an external tool element with tool 'CY Test Tool 1' - # Teacher tries to add a preferred tool with context restriction course - When I click on plus icon to add card in column - When I click on plus icon to add content into card - Then I do not see preferred tool 'CY Test Tool Preferred Course Restriction' in the menu - # Teacher adds a preferred tool with context restriction board - Then I see preferred tool 'CY Test Tool Preferred Board Restriction' in the menu - When I select preferred tool 'CY Test Tool Preferred Board Restriction' from the menu - Then I see an external tool element with tool 'CY Test Tool Preferred Board Restriction' - - # Teacher sees ctl tools with context restriction media-board in the media-shelf - When I go to media shelf - Then I see the media shelf page title - Then I see the available media line - Then I see 3 tools in the available media line - Then I see tool 'CY Test Tool 1' in the available media line - Then I see tool 'CY Test Tool Media-Board Restriction' in the available media line - Then I see tool 'CY Test Tool All Restrictions' in the available media line - Then I do not see tool 'CY Test Tool Course Restriction' in the available media line - Then I do not see tool 'CY Test Tool Board-Element Restriction' in the available media line - - @unstable_test - Scenario: Post-test: Admin deletes a course and external tools - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I go to course administration page - When I click the delete button for course 'Cypress Test Course' in course table - Then I see the delete modal - When I click the confirmation button on the delete modal - Then I do not see course 'Cypress Test Course' in course table - - # Admin deletes external tools - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table - When I click on delete button of tool 'CY Test Tool 1' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool Course Restriction' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool Board-Element Restriction' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool Media-Board Restriction' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool All Restrictions' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool Preferred Course Restriction' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool Preferred Board Restriction' - When I confirm deletion on deletion dialog diff --git a/cypress/e2e/course/contextRestrictionOfCtlToolsInCourse.feature b/cypress/e2e/course/contextRestrictionOfCtlToolsInCourse.feature new file mode 100644 index 00000000..9d2808f4 --- /dev/null +++ b/cypress/e2e/course/contextRestrictionOfCtlToolsInCourse.feature @@ -0,0 +1,130 @@ +@regression_test +@stable_test +Feature: Media Shelf - Restrict CTL tools to context course + + As a teacher I want to add ctl tools with context restriction course + + @stable_test + Scenario: Teacher adds tools with context restriction course in a course + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin creates a course + When I go to courses overview + When I click on FAB to create a new course depending on sub menu + Then I see section one area on the course create page + When I enter the course title 'Cypress Test Course' + When I select 'Karl Herzog' from field teacher + When I click on button Next Steps after entering the course detail in section one + Then I see section two area on the course create page + When I click on button Next Steps after selecting course participant details + Then I see the section three area as the finish page + When I click on button To Course Overview on the finish page + + # Admin adds external tools with context restriction to school + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + When I click the add external tool button + When I select the tool 'CY Test Tool 1' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' in external tools table has no context restriction + When I click the add external tool button + When I select the tool 'CY Test Tool Course Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Course Restriction' in external tools table + Then I see the tool 'CY Test Tool Course Restriction' in external tools table has context restriction 'Kurs-Tools' + When I click the add external tool button + When I select the tool 'CY Test Tool Board-Element Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table + Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table has context restriction 'Bereiche' + When I click the add external tool button + When I select the tool 'CY Test Tool Media-Board Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table + Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table has context restriction 'Medienregal' + When I click the add external tool button + When I select the tool 'CY Test Tool All Restrictions' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool All Restrictions' in external tools table + Then I see the tool 'CY Test Tool All Restrictions' in external tools table has context restriction 'Kurs-Tools, Bereiche, Medienregal' + When I click the add external tool button + + # Teacher tries to a tool with context restriction board-element + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on the tools tab + Then I see the button to add a tool + When I click on the button to add a tool + Then I see the tool configuration page title + When I click on the tool configuration selection + Then I do not see tool 'CY Test Tool Board-Element Restriction' in the tool selection + # Teacher tries to a tool with context restriction media-board + Then I do not see tool 'CY Test Tool Media-Board Restriction' in the tool selection + + # Teacher adds a tool with context restriction course + When I select the tool 'CY Test Tool Course Restriction' from available tools + Then I see tool 'CY Test Tool Course Restriction' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool Course Restriction' in the tool overview + + # Teacher adds a tool with all context restrictions + When I click on the button to add a tool + Then I see the tool configuration page title + When I click on the tool configuration selection + When I select the tool 'CY Test Tool All Restrictions' from available tools + Then I see tool 'CY Test Tool All Restrictions' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool All Restrictions' in the tool overview + + # Teacher adds a tool without any context restriction + When I click on the button to add a tool + Then I see the tool configuration page title + When I click on the tool configuration selection + When I select the tool 'CY Test Tool 1' from available tools + Then I see tool 'CY Test Tool 1' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in the tool overview + + # Post-condition: Admin deletes course + Given I am logged in as a '' at '' + When I click on administration in menu + When I go to course administration page + When I click the delete button for course 'Cypress Test Course' in course table + Then I see the delete modal + When I click the confirmation button on the delete modal + Then I do not see course 'Cypress Test Course' in course table + + # Post-condition: Admin deletes external tools + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool 1' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table + When I click on delete button of tool 'CY Test Tool Course Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Course Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool Board-Element Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Board-Element Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool Media-Board Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Media-Board Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool All Restrictions' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool All Restrictions' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | namespace | + | admin1_nbc | teacher1_nbc | nbc | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/e2e/course/deactivationOfCtlTools.feature b/cypress/e2e/course/deactivationOfCtlTools.feature deleted file mode 100644 index ec63681f..00000000 --- a/cypress/e2e/course/deactivationOfCtlTools.feature +++ /dev/null @@ -1,261 +0,0 @@ -@unstable_test -Feature: Deactivation of ctl tools - - As a Admin I want to deactivate und activate an external tool - - @unstable_test - Scenario: Pre-test: Admin creates a course - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I go to courses overview - When I click on FAB to create a new course depending on sub menu - When I enter the course title 'Cypress Test Course' - When I select 'Karl Herzog' from field teacher - When I click on button Next Steps after entering the course detail in section one - When I select 'Amelia Strobl' from field student - When I click on button Next Steps after selecting course participant details - When I click on button To Course Overview on the finish page - - @unstable_test - Scenario: Admin tries to add an deactivated external tool, adds an external tool and deactivates and activates it - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table is empty - When I click the add external tool button - Then I see the external tools configuration page - Then I see the external tool configuration page title - Then I see the tool configuration infotext - # Admin tries to add an deactivated external tool - Then I do not see external tool 'CY Test Tool deactivated External Tool' in the tool selection - # Admin adds a tool - When I select the tool 'CY Test Tool 1' from available tools - Then I see tool 'CY Test Tool 1' is selected - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in external tools table - Then I see the tool 'CY Test Tool 1' is active in tools table - # Admin adds a tool and deactivates it - When I click the add external tool button - Then I see the external tools configuration page - Then I see the external tool configuration page title - Then I see the tool configuration infotext - When I select the tool 'CY Test Tool 2' from available tools - Then I see tool 'CY Test Tool 2' is selected - When I deactivate the tool - Then I see the deactivate checkbox is 'checked' - When I click on save external tool button - Then I see the tool 'CY Test Tool 2' in external tools table - Then I see the tool 'CY Test Tool 2' is deactivated in external tools table - - # Teacher can not add a deactivated tool in course - Given I am logged in as a 'teacher1_nbc' at 'nbc' - When I go to courses overview - When I go to course 'Cypress Test Course' - Then I see course page 'Cypress Test Course' - When I click on the tools tab - Then I see the button to add a tool - When I click on the button to add a tool - Then I see the tool configuration page title - When I click on the tool configuration selection - # Teacher tries to a deactivated tool - Then I do not see tool 'CY Test Tool 2' in the tool selection - # Teacher adds a activated tool - When I click on the tool configuration selection - When I select the tool 'CY Test Tool 1' from available tools - Then I see tool 'CY Test Tool 1' is selected - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in the tool overview - - # Teacher can not add a deactivated tool to a board - When I go to the tab contents in course detail page - When I click on FAB to create new content - When I click on the button FAB New Column Board - Then I see a dialog box for column board - When I choose multi-column board in the dialog box - Then I see the page Course Board details - Then I see the chip Draft in the course board - When I click on three dot menu in the board header - When I click on the option Publish in three dot menu in course board - Then I do not see the chip Draft in the course board - When I click on the button Add column in the course board - When I click on the page outside of the column - When I click on plus icon to add card in column - When I click on plus icon to add content into card - When I select external tools from the menu - When I click on the tool configuration selection - # Teacher tries to a deactivated tool - Then I do not see tool 'CY Test Tool 2' in the tool selection - # Teacher adds a activated tool - When I click on the tool configuration selection - When I select the tool 'CY Test Tool 1' from available tools - Then I see tool 'CY Test Tool 1' is selected - When I click on save external tool button - Then I see an external tool element with tool 'CY Test Tool 1' - - # Admin deactivates an existing tool - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table - Then I see the tool 'CY Test Tool 1' in external tools table - When I click on edit button of tool 'CY Test Tool 1' - Then I see the external tools configuration page - Then I see the external tool configuration page title - Then I see the tool configuration infotext - Then I see tool 'CY Test Tool 1' is selected - When I deactivate the tool - Then I see the deactivate checkbox is 'checked' - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in external tools table - Then I see the tool 'CY Test Tool 1' is deactivated in external tools table - - # Teacher tries to launch a deactivated tool in course - Given I am logged in as a 'teacher1_nbc' at 'nbc' - When I go to courses overview - When I go to course 'Cypress Test Course' - Then I see course page 'Cypress Test Course' - When I click on the tools tab - Then I see the tool 'CY Test Tool 1' in the tool overview - Then I see the tool 'CY Test Tool 1' is marked as deactivated - When I click on the tool 'CY Test Tool 1' - Then I see an error dialog - When I close the dialog - Then I see 1 tools - - # Teacher tries to launch a deactivated tool in board - When I go to the tab contents in course detail page - When I click on card Course Board - Then I see the page Course Board details - Then I see an external tool element with tool 'CY Test Tool 1' - Then I see an external tool element with tool 'CY Test Tool 1' is marked as deactivated - # Teacher tries to launch incomplete tool - When I click on external tool element with tool 'CY Test Tool 1' - # Then nothing should happen - - - # Student tries to launch a deactivated tool in course - Given I am logged in as a 'student2_nbc' at 'nbc' - When I go to courses overview - When I go to course 'Cypress Test Course' - Then I see course page 'Cypress Test Course' - When I click on the tools tab - Then I see the tool 'CY Test Tool 1' in the tool overview - Then I see the tool 'CY Test Tool 1' is marked as deactivated - When I click on the tool 'CY Test Tool 1' - Then I see an error dialog - When I close the dialog - Then I see 1 tools - - # Student tries to launch a deactivated tool in board - When I go to the tab contents in course detail page - When I click on card Course Board - Then I see the page Course Board details - Then I see an external tool element with tool 'CY Test Tool 1' - Then I see an external tool element with tool 'CY Test Tool 1' is marked as deactivated - # Student tries to launch incomplete tool - When I click on external tool element with tool 'CY Test Tool 1' - # Then nothing should happen - - # Admin activates existing deactivated tools - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table - Then I see the tool 'CY Test Tool 1' in external tools table - When I click on edit button of tool 'CY Test Tool 1' - Then I see the external tools configuration page - Then I see the external tool configuration page title - Then I see the tool configuration infotext - Then I see tool 'CY Test Tool 1' is selected - When I activate the tool - Then I see the deactivate checkbox is 'not checked' - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in external tools table - Then I see the tool 'CY Test Tool 1' is active in tools table - Then I see the tool 'CY Test Tool 2' in external tools table - When I click on edit button of tool 'CY Test Tool 2' - Then I see the external tools configuration page - Then I see the external tool configuration page title - Then I see the tool configuration infotext - Then I see tool 'CY Test Tool 2' is selected - When I activate the tool - Then I see the deactivate checkbox is 'not checked' - When I click on save external tool button - Then I see the tool 'CY Test Tool 2' in external tools table - Then I see the tool 'CY Test Tool 2' is active in tools table - - # Teacher adds activated tool to course - Given I am logged in as a 'teacher1_nbc' at 'nbc' - When I go to courses overview - When I go to course 'Cypress Test Course' - Then I see course page 'Cypress Test Course' - When I click on the tools tab - Then I see the tool 'CY Test Tool 1' in the tool overview - Then I see the tool 'CY Test Tool 1' is not marked as deactivated - Then I see the button to add a tool - When I click on the button to add a tool - Then I see the tool configuration page title - When I click on the tool configuration selection - When I select the tool 'CY Test Tool 2' from available tools - Then I see tool 'CY Test Tool 2' is selected - When I click on save external tool button - Then I see the tool 'CY Test Tool 2' in the tool overview - - # Teacher adds activated tool to a board - When I go to the tab contents in course detail page - When I click on card Course Board - Then I see the page Course Board details - Then I see an external tool element with tool 'CY Test Tool 1' - Then I see an external tool element with tool 'CY Test Tool 1' is not marked as deactivated - When I click on three dot menu in the card - When I select the option Edit in three dot menu on the card - When I click on plus icon to add content into card - When I select external tools from the menu - When I click on the tool configuration selection - When I select the tool 'CY Test Tool 2' from available tools - Then I see tool 'CY Test Tool 2' is selected - When I click on save external tool button - Then I see an external tool element with tool 'CY Test Tool 2' - - - # Student sees activated tools in course - Given I am logged in as a 'student2_nbc' at 'nbc' - When I go to courses overview - When I go to course 'Cypress Test Course' - Then I see course page 'Cypress Test Course' - When I click on the tools tab - Then I see the tool 'CY Test Tool 1' in the tool overview - Then I see the tool 'CY Test Tool 1' is not marked as deactivated - Then I see the tool 'CY Test Tool 2' in the tool overview - Then I see the tool 'CY Test Tool 2' is not marked as deactivated - - # Student tries to launch a deactivated tool in board - When I go to the tab contents in course detail page - When I click on card Course Board - Then I see the page Course Board details - Then I see an external tool element with tool 'CY Test Tool 1' - Then I see an external tool element with tool 'CY Test Tool 1' is not marked as deactivated - Then I see an external tool element with tool 'CY Test Tool 2' - Then I see an external tool element with tool 'CY Test Tool 2' is not marked as deactivated - - @unstable_test - Scenario: Post-test: Teacher deletes course, admin deletes external tools - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I go to course administration page - When I click the delete button for course 'Cypress Test Course' in course table - Then I see the delete modal - When I click the confirmation button on the delete modal - Then I do not see course 'Cypress Test Course' in course table - - # Admin deletes external tools - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table - When I click on delete button of tool 'CY Test Tool 1' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool 2' - When I confirm deletion on deletion dialog diff --git a/cypress/e2e/course/deactivationOfCtlToolsInCourse.feature b/cypress/e2e/course/deactivationOfCtlToolsInCourse.feature new file mode 100644 index 00000000..50f9c6e2 --- /dev/null +++ b/cypress/e2e/course/deactivationOfCtlToolsInCourse.feature @@ -0,0 +1,195 @@ +@regression_test +@stable_test +Feature: Deactivation of ctl tools in course + + As a user I want to see deactivated und activated tools in a course + + @stable_test + Scenario Outline: Users see deactivated tool in course + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin creates a course + When I go to courses overview + When I click on FAB to create a new course depending on sub menu + Then I see section one area on the course create page + When I enter the course title 'Cypress Test Course' + When I select '' from field teacher + When I click on button Next Steps after entering the course detail in section one + Then I see section two area on the course create page + When I select '' from field student + When I click on button Next Steps after selecting course participant details + Then I see the section three area as the finish page + When I click on button To Course Overview on the finish page + + # Admin tries to add an deactivated external tool + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table is empty + When I click the add external tool button + Then I see the external tools configuration page + Then I do not see external tool 'CY Test Tool deactivated External Tool' in the tool selection + # Admin adds a tool + When I select the tool 'CY Test Tool 1' from available tools + Then I see tool 'CY Test Tool 1' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' is active in tools table + # Admin adds a tool and deactivates it + When I click the add external tool button + Then I see the external tools configuration page + When I select the tool 'CY Test Tool 2' from available tools + Then I see tool 'CY Test Tool 2' is selected + When I deactivate the tool + Then I see the deactivate checkbox is 'checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 2' in external tools table + Then I see the tool 'CY Test Tool 2' is deactivated in external tools table + + # Teacher tries to add a deactivated tool in course + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on the tools tab + Then I see the button to add a tool + When I click on the button to add a tool + Then I see the tool configuration page title + When I click on the tool configuration selection + Then I do not see tool 'CY Test Tool 2' in the tool selection + # Teacher adds a activated tool + When I click on the tool configuration selection + When I select the tool 'CY Test Tool 1' from available tools + Then I see tool 'CY Test Tool 1' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in the tool overview + + # Admin deactivates an existing tool + Given I am logged in as a '' at '' + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + Then I see the tool 'CY Test Tool 1' in external tools table + When I click on edit button of tool 'CY Test Tool 1' + Then I see the external tools configuration page + Then I see the external tool configuration page title + Then I see the tool configuration infotext + Then I see tool 'CY Test Tool 1' is selected + When I deactivate the tool + Then I see the deactivate checkbox is 'checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' is deactivated in external tools table + + # Teacher tries to launch a deactivated tool in course + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on the tools tab + Then I see the tool 'CY Test Tool 1' in the tool overview + Then I see the tool 'CY Test Tool 1' is marked as deactivated + When I click on the tool 'CY Test Tool 1' + Then I see an error dialog + When I close the dialog + Then I see 1 tools + + # Student sees that a tool is marked as deactivated in course + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on the tools tab + Then I see the tool 'CY Test Tool 1' in the tool overview + Then I see the tool 'CY Test Tool 1' is marked as deactivated + # Student tries to launch a deactivated tool in course + When I click on the tool 'CY Test Tool 1' + Then I see an error dialog + When I close the dialog + Then I see 1 tools + + # Admin activates existing deactivated tools + Given I am logged in as a '' at '' + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + Then I see the tool 'CY Test Tool 1' in external tools table + When I click on edit button of tool 'CY Test Tool 1' + Then I see the external tools configuration page + Then I see tool 'CY Test Tool 1' is selected + When I activate the tool + Then I see the deactivate checkbox is 'not checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' is active in tools table + Then I see the tool 'CY Test Tool 2' in external tools table + When I click on edit button of tool 'CY Test Tool 2' + Then I see the tool configuration infotext + Then I see tool 'CY Test Tool 2' is selected + When I activate the tool + Then I see the deactivate checkbox is 'not checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 2' in external tools table + Then I see the tool 'CY Test Tool 2' is active in tools table + + # Teacher adds activated tool to course + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on the tools tab + Then I see the tool 'CY Test Tool 1' in the tool overview + Then I see the tool 'CY Test Tool 1' is not marked as deactivated + Then I see the button to add a tool + When I click on the button to add a tool + Then I see the tool configuration page title + When I click on the tool configuration selection + When I select the tool 'CY Test Tool 2' from available tools + Then I see tool 'CY Test Tool 2' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool 2' in the tool overview + + # Student sees activated tools in course + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on the tools tab + Then I see the tool 'CY Test Tool 1' in the tool overview + Then I see the tool 'CY Test Tool 1' is not marked as deactivated + Then I see the tool 'CY Test Tool 2' in the tool overview + Then I see the tool 'CY Test Tool 2' is not marked as deactivated + + # Post-condition: Admin deletes course + Given I am logged in as a '' at '' + When I click on administration in menu + When I go to course administration page + When I click the delete button for course 'Cypress Test Course' in course table + Then I see the delete modal + When I click the confirmation button on the delete modal + Then I do not see course 'Cypress Test Course' in course table + + # Post-condition: Admin deletes external tools + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool 1' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table + When I click on delete button of tool 'CY Test Tool 2' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 2' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | student | namespace | fullname_teacher | fullname_student | + | admin1_nbc | teacher1_nbc | student1_nbc | nbc | Karl Herzog | Herbert Kraft | + + # @school_api_test + # This feature is not executable with the school_api \ No newline at end of file diff --git a/cypress/e2e/course_board/createEditDeleteCtlToolInBoard.feature b/cypress/e2e/course_board/addEditDeleteCtlToolInBoard.feature similarity index 74% rename from cypress/e2e/course_board/createEditDeleteCtlToolInBoard.feature rename to cypress/e2e/course_board/addEditDeleteCtlToolInBoard.feature index b89451e8..25dc5344 100644 --- a/cypress/e2e/course_board/createEditDeleteCtlToolInBoard.feature +++ b/cypress/e2e/course_board/addEditDeleteCtlToolInBoard.feature @@ -1,13 +1,16 @@ -@unstable_test +@regression_test +@stable_test Feature: Course Board - To add, edit and delete a ctl tool in a board - As a teacher I want to add, edit and delete a ctl tool in my course Board + As a teacher I want to add, edit and delete a ctl tool in my course board - @unstable_test - Scenario: Pre-test: Admin creates a course and adds external tools to school - Given I am logged in as a 'admin1_nbc' at 'nbc' + @stable_test + Scenario Outline: Teacher adds, edits and deletes tools in a course board + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin creates a course When I go to courses overview - # Admin creates a course When I click on FAB to create a new course depending on sub menu Then I see section one area on the course create page When I enter the course title 'Cypress Test Course' @@ -18,7 +21,7 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board Then I see the section three area as the finish page When I click on button To Course Overview on the finish page - # Admin adds tools via selection + # Pre-condition: Admin adds external tools to school When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel @@ -35,26 +38,16 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board When I select the tool 'CY Test Tool Optional Parameters' from available tools When I click on save external tool button Then I see the tool 'CY Test Tool Optional Parameters' in external tools table - When I click the add external tool button - When I select the tool 'CY Test Tool Preferred' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Preferred' in external tools table - When I click the add external tool button - When I select the tool 'CY Test Tool Preferred With Param' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool Preferred With Param' in external tools table - # Admin adds tools via tool link When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel When I click the add external tool button When I insert the external tool link 'https://www.openstreetmap.org/?mlat=52.40847&mlon=9.80823&zoom=19#map=19/52.40847/9.80823' When I click on save external tool button - Then I see the tool 'OpenStreetMap' in external tools table + Then I see the tool 'CY Test Tool OpenStreetMap' in external tools table - @unstable_test - Scenario: Teacher adds, edits and deletes tools in a column board - Given I am logged in as a 'teacher1_nbc' at 'nbc' + # Teacher adds a tool without a custom parameter + Given I am logged in as a '' at '' When I go to courses overview When I go to course 'Cypress Test Course' When I go to the tab contents in course detail page @@ -68,8 +61,6 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board Then I see the chip Draft in the course board When I click on the button Add column in the course board When I click on the page outside of the column - - # Teacher adds a tool without a custom parameter When I click on plus icon to add card in column When I click on plus icon to add content into card When I select external tools from the menu @@ -78,11 +69,11 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board Then I see tool 'CY Test Tool 1' is selected When I click on save external tool button Then I see an external tool element with tool 'CY Test Tool 1' - # Teacher launches tool + # Teacher launches tool When I launch tool 'CY Test Tool 1' on external tool element with given url 'https://google.com/' Then I see tool 'CY Test Tool 1' on external tool element was launched - # Teacher adds a tool twice with different name + # Teacher adds a tool twice but with a different name When I click on three dot menu in the card When I select the option Edit in three dot menu on the card When I click on plus icon to add content into card @@ -94,21 +85,21 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board When I click on save external tool button Then I see an external tool element with tool 'CY Test Tool 1 New' - # Teacher adds tool via tool link + # Teacher adds tool via tool link When I click on three dot menu in the card When I select the option Edit in three dot menu on the card When I click on plus icon to add content into card When I select external tools from the menu When I click on the tool configuration selection When I insert the external tool link 'https://www.openstreetmap.org/?mlat=52.40847&mlon=9.80823&zoom=19#map=19/52.40847/9.80823' - Then I see tool 'OpenStreetMap' is selected + Then I see tool 'CY Test Tool OpenStreetMap' is selected Then I see configuration 'mlat' is filled below with '52.40847' Then I see configuration 'mlon' is filled below with '9.80823' Then I see configuration 'zoom' is filled below with '19' When I click on save external tool button - Then I see an external tool element with tool 'OpenStreetMap' + Then I see an external tool element with tool 'CY Test Tool OpenStreetMap' - # Teacher adds tool with a required custom parameter + # Teacher adds tool with a required custom parameter When I click on three dot menu in the card When I select the option Edit in three dot menu on the card When I click on plus icon to add content into card @@ -116,7 +107,7 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board When I click on the tool configuration selection When I select the tool 'CY Test Tool Required Parameters' from available tools Then I see tool 'CY Test Tool Required Parameters' is selected - # when required field is empty + # When required field is empty When I click on save external tool button Then I see an error alert When I enter 'test' in required custom parameter field 'contextParam' @@ -124,7 +115,7 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board When I click on save external tool button Then I see an external tool element with tool 'CY Test Tool Required Parameters' - # Teacher adds a tool with an optional custom parameter + # Teacher adds a tool with an optional custom parameter When I click on three dot menu in the card When I select the option Edit in three dot menu on the card When I click on plus icon to add content into card @@ -137,7 +128,7 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board When I click on save external tool button Then I see an external tool element with tool 'CY Test Tool Optional Parameters' - # Teacher edits a tool + # Teacher edits a tool When I click on three dot menu in the card When I select the option Edit in three dot menu on the card When I click on three dot menu of external tool element 'CY Test Tool Optional Parameters' @@ -154,32 +145,15 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board Then I see custom parameter input field 'contextParam' contains 'updated test' When I click on save external tool button - # Teacher deletes tools from board + # Teacher deletes tools from board When I click on three dot menu in the card When I select the option Edit in three dot menu on the card When I click on three dot menu of external tool element 'CY Test Tool Optional Parameters' When I click the delete button in three dot menu on the element When I click on the button Remove on the Modal - # Add preferred tools - When I click on three dot menu in the card - When I select the option Edit in three dot menu on the card - When I click on plus icon to add content into card - Then I see preferred tool 'CY Test Tool Preferred' in the menu - When I select preferred tool 'CY Test Tool Preferred' from the menu - Then I see an external tool element with tool 'CY Test Tool Preferred' - When I click on plus icon to add content into card - Then I see preferred tool 'CY Test Tool Preferred With Param' in the menu - When I select preferred tool 'CY Test Tool Preferred With Param' from the menu - Then I see tool 'CY Test Tool Preferred With Param' is selected - When I enter 'test' in required custom parameter field 'contextParam' - Then I see custom parameter input field 'contextParam' contains 'test' - When I click on save external tool button - Then I see an external tool element with tool 'CY Test Tool Preferred With Param' - - @unstable_test - Scenario: Post-test: Admin deletes a course and external tools - Given I am logged in as a 'admin1_nbc' at 'nbc' + # Post-condition: Admin deletes course + Given I am logged in as a '' at '' When I click on administration in menu When I go to course administration page When I click the delete button for course 'Cypress Test Course' in course table @@ -187,20 +161,29 @@ Feature: Course Board - To add, edit and delete a ctl tool in a board When I click the confirmation button on the delete modal Then I do not see course 'Cypress Test Course' in course table - # Admin deletes external tools + # Post-condition: Admin deletes tools When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel Then I see the external tools table - When I click on delete button of tool 'CY Test Tool Preferred' - When I confirm deletion on deletion dialog - When I click on delete button of tool 'CY Test Tool Preferred With Param' - When I confirm deletion on deletion dialog When I click on delete button of tool 'CY Test Tool 1' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table When I click on delete button of tool 'CY Test Tool Required Parameters' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Required Parameters' in external tools table When I click on delete button of tool 'CY Test Tool Optional Parameters' When I confirm deletion on deletion dialog - When I click on delete button of tool 'OpenStreetMap' + Then I do not see the tool 'CY Test Tool Optional Parameters' in external tools table + When I click on delete button of tool 'CY Test Tool OpenStreetMap' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool OpenStreetMap' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | namespace | fullname_teacher | + | admin1_nbc | teacher1_nbc | nbc | Karl Herzog | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/e2e/course_board/addPreferredCtlToolInBoard.feature b/cypress/e2e/course_board/addPreferredCtlToolInBoard.feature new file mode 100644 index 00000000..9603bf40 --- /dev/null +++ b/cypress/e2e/course_board/addPreferredCtlToolInBoard.feature @@ -0,0 +1,99 @@ +# @regression_test +# @stable_test +# Note: The test was set to unstable because the required feature flag (FEATURE_PREFERRED_CTL_TOOLS_ENABLED) is not yet activated in staging +@unstable_test +Feature: Course Board - To add a preferred tool in a board + + As a teacher I want to add a preferred tool in my course board + + # @stable_test + @unstable_test + Scenario Outline: Teacher adds, edits and deletes tools in a course board + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin creates a course + When I go to courses overview + When I click on FAB to create a new course depending on sub menu + Then I see section one area on the course create page + When I enter the course title 'Cypress Test Course' + When I select 'Karl Herzog' from field teacher + When I click on button Next Steps after entering the course detail in section one + Then I see section two area on the course create page + When I click on button Next Steps after selecting course participant details + Then I see the section three area as the finish page + When I click on button To Course Overview on the finish page + + # Pre-condition: Admin adds preferred tools + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + When I click the add external tool button + When I select the tool 'CY Test Tool Preferred' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Preferred' in external tools table + When I click the add external tool button + When I select the tool 'CY Test Tool Preferred With Param' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Preferred With Param' in external tools table + + # Teacher adds a preferred tool without a custom parameter + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + When I go to the tab contents in course detail page + When I click on FAB to create new content + When I click on the button FAB New Column Board + Then I see a dialog box for column board + Then I see in dialog box option for multi-column board + Then I see in dialog box option for single column board + When I choose multi-column board in the dialog box + Then I see the page Course Board details + Then I see the chip Draft in the course board + When I click on the button Add column in the course board + When I click on the page outside of the column + When I click on plus icon to add card in column + When I click on plus icon to add content into card + Then I see preferred tool 'CY Test Tool Preferred' in the menu + When I select preferred tool 'CY Test Tool Preferred' from the menu + Then I see an external tool element with tool 'CY Test Tool Preferred' + + # Teacher adds a preferred tool with a custom parameter + When I click on plus icon to add content into card + Then I see preferred tool 'CY Test Tool Preferred With Param' in the menu + When I select preferred tool 'CY Test Tool Preferred With Param' from the menu + Then I see tool 'CY Test Tool Preferred With Param' is selected + When I enter 'test' in required custom parameter field 'contextParam' + Then I see custom parameter input field 'contextParam' contains 'test' + When I click on save external tool button + Then I see an external tool element with tool 'CY Test Tool Preferred With Param' + + # Post-condition: Admin deletes course + Given I am logged in as a '' at '' + When I click on administration in menu + When I go to course administration page + When I click the delete button for course 'Cypress Test Course' in course table + Then I see the delete modal + When I click the confirmation button on the delete modal + Then I do not see course 'Cypress Test Course' in course table + + # Post-condition: Admin deletes tools + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool Preferred With Param' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Preferred With Param' in external tools table + When I click on delete button of tool 'CY Test Tool Preferred' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Preferred' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | namespace | fullname_teacher | + | admin1_nbc | teacher1_nbc | nbc | Karl Herzog | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/e2e/course_board/contextRestrictionOfCtlToolsInBoard.feature b/cypress/e2e/course_board/contextRestrictionOfCtlToolsInBoard.feature new file mode 100644 index 00000000..90c1daa1 --- /dev/null +++ b/cypress/e2e/course_board/contextRestrictionOfCtlToolsInBoard.feature @@ -0,0 +1,171 @@ +@regression_test +@stable_test +Feature: Media Shelf - Restrict CTL tools to context board-element + + As a teacher I want to add ctl tools with context restriction board-element + + @stable_test + Scenario: Teacher adds tools with context restriction board-element in a board + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin creates a course + When I go to courses overview + When I click on FAB to create a new course depending on sub menu + Then I see section one area on the course create page + When I enter the course title 'Cypress Test Course' + When I select 'Karl Herzog' from field teacher + When I click on button Next Steps after entering the course detail in section one + Then I see section two area on the course create page + When I click on button Next Steps after selecting course participant details + Then I see the section three area as the finish page + When I click on button To Course Overview on the finish page + + # Pre-condition: Admin adds external tools to school + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + When I click the add external tool button + When I select the tool 'CY Test Tool 1' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' in external tools table has no context restriction + When I click the add external tool button + When I select the tool 'CY Test Tool Course Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Course Restriction' in external tools table + Then I see the tool 'CY Test Tool Course Restriction' in external tools table has context restriction 'Kurs-Tools' + When I click the add external tool button + When I select the tool 'CY Test Tool Board-Element Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table + Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table has context restriction 'Bereiche' + When I click the add external tool button + When I select the tool 'CY Test Tool Media-Board Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table + Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table has context restriction 'Medienregal' + When I click the add external tool button + When I select the tool 'CY Test Tool All Restrictions' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool All Restrictions' in external tools table + Then I see the tool 'CY Test Tool All Restrictions' in external tools table has context restriction 'Kurs-Tools, Bereiche, Medienregal' + # Note: This steps are commented out because the required feature flag (FEATURE_PREFERRED_CTL_TOOLS_ENABLED) is not yet activated in staging + # When I click the add external tool button + # When I select the tool 'CY Test Tool Preferred Course Restriction' from available tools + # When I click on save external tool button + # Then I see the tool 'CY Test Tool Preferred Course Restriction' in external tools table + # Then I see the tool 'CY Test Tool Preferred Course Restriction' in external tools table has context restriction 'Kurs-Tools' + # When I click the add external tool button + # When I select the tool 'CY Test Tool Preferred Board Restriction' from available tools + # When I click on save external tool button + # Then I see the tool 'CY Test Tool Preferred Board Restriction' in external tools table + # Then I see the tool 'CY Test Tool Preferred Board Restriction' in external tools table has context restriction 'Bereiche' + + # Teacher tries to add a tool with context restriction course + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on FAB to create new content + When I click on the button FAB New Column Board + Then I see a dialog box for column board + Then I see in dialog box option for multi-column board + Then I see in dialog box option for single column board + When I choose multi-column board in the dialog box + Then I see the page Course Board details + Then I see the chip Draft in the course board + When I click on the button Add column in the course board + When I click on the page outside of the column + When I click on plus icon to add card in column + When I click on plus icon to add content into card + When I select external tools from the menu + When I click on the tool configuration selection + Then I do not see tool 'CY Test Tool Course Restriction' in the tool selection + # Teacher tries to add a tool with context restriction media-board + Then I do not see tool 'CY Test Tool Media-Board Restriction' in the tool selection + + # Teacher adds a tool with context restriction board-element + When I select the tool 'CY Test Tool Board-Element Restriction' from available tools + Then I see tool 'CY Test Tool Board-Element Restriction' is selected + When I click on save external tool button + Then I see an external tool element with tool 'CY Test Tool Board-Element Restriction' + + # Teacher adds a tool with all context restrictions + When I click on three dot menu in the card + When I select the option Edit in three dot menu on the card + When I click on plus icon to add content into card + When I select external tools from the menu + When I select the tool 'CY Test Tool All Restrictions' from available tools + Then I see tool 'CY Test Tool All Restrictions' is selected + When I click on save external tool button + Then I see an external tool element with tool 'CY Test Tool All Restrictions' + + # Teacher adds a tool without any context restriction + When I click on three dot menu in the card + When I select the option Edit in three dot menu on the card + When I click on plus icon to add content into card + When I select external tools from the menu + When I select the tool 'CY Test Tool 1' from available tools + Then I see tool 'CY Test Tool 1' is selected + When I click on save external tool button + Then I see an external tool element with tool 'CY Test Tool 1' + + # Note: This steps are commented out because the required feature flag (FEATURE_PREFERRED_CTL_TOOLS_ENABLED) is not yet activated in staging + # # Teacher tries to add a preferred tool with context restriction course + # When I click on three dot menu in the card + # When I select the option Edit in three dot menu on the card + # When I click on plus icon to add content into card + # Then I do not see preferred tool 'CY Test Tool Preferred Course Restriction' in the menu + + # Note: This steps are commented out because the required feature flag (FEATURE_PREFERRED_CTL_TOOLS_ENABLED) is not yet activated in staging + # # Teacher adds a preferred tool with context restriction board + # Then I see preferred tool 'CY Test Tool Preferred Board Restriction' in the menu + # When I select preferred tool 'CY Test Tool Preferred Board Restriction' from the menu + # Then I see an external tool element with tool 'CY Test Tool Preferred Board Restriction' + + # Post-condition: Admin deletes course + Given I am logged in as a '' at '' + When I click on administration in menu + When I go to course administration page + When I click the delete button for course 'Cypress Test Course' in course table + Then I see the delete modal + When I click the confirmation button on the delete modal + Then I do not see course 'Cypress Test Course' in course table + + # Post-condition: Admin deletes external tools + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool 1' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table + When I click on delete button of tool 'CY Test Tool Course Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Course Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool Board-Element Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Board-Element Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool Media-Board Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Media-Board Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool All Restrictions' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool All Restrictions' in external tools table + # Note: This steps are commented out because the required feature flag (FEATURE_PREFERRED_CTL_TOOLS_ENABLED) is not yet activated in staging + # When I click on delete button of tool 'CY Test Tool Preferred Course Restriction' + # When I confirm deletion on deletion dialog + # Then I do not see the tool 'CY Test Tool Preferred Course Restriction' in external tools table + # When I click on delete button of tool 'CY Test Tool Preferred Board Restriction' + # When I confirm deletion on deletion dialog + # Then I do not see the tool 'CY Test Tool Preferred Board Restriction' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | namespace | + | admin1_nbc | teacher1_nbc | nbc | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/e2e/course_board/deactivationOfCtlToolsInBoard.feature b/cypress/e2e/course_board/deactivationOfCtlToolsInBoard.feature new file mode 100644 index 00000000..c5d51357 --- /dev/null +++ b/cypress/e2e/course_board/deactivationOfCtlToolsInBoard.feature @@ -0,0 +1,206 @@ +@regression_test +@stable_test +Feature: Deactivation of ctl tools in board + + As a user I want to see deactivated und activated tools in a board + + @stable_test + Scenario Outline: Users see deactivated tool in board + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin creates a course + When I go to courses overview + When I click on FAB to create a new course depending on sub menu + Then I see section one area on the course create page + When I enter the course title 'Cypress Test Course' + When I select '' from field teacher + When I click on button Next Steps after entering the course detail in section one + Then I see section two area on the course create page + When I select '' from field student + When I click on button Next Steps after selecting course participant details + Then I see the section three area as the finish page + When I click on button To Course Overview on the finish page + + # Pre-condition: Admin adds a tool + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table is empty + When I click the add external tool button + Then I see the external tools configuration page + When I select the tool 'CY Test Tool 1' from available tools + Then I see tool 'CY Test Tool 1' is selected + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' is active in tools table + # Pre-condition: Admin adds a tool and deactivates it + When I click the add external tool button + Then I see the external tools configuration page + When I select the tool 'CY Test Tool 2' from available tools + Then I see tool 'CY Test Tool 2' is selected + When I deactivate the tool + Then I see the deactivate checkbox is 'checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 2' in external tools table + Then I see the tool 'CY Test Tool 2' is deactivated in external tools table + + # Teacher tries to add a deactivated tool in board + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on FAB to create new content + When I click on the button FAB New Column Board + Then I see a dialog box for column board + When I choose multi-column board in the dialog box + Then I see the page Course Board details + Then I see the chip Draft in the course board + When I click on three dot menu in the board header + When I click on the option Publish in three dot menu in course board + Then I do not see the chip Draft in the course board + When I click on the button Add column in the course board + When I click on the page outside of the column + When I click on plus icon to add card in column + When I click on plus icon to add content into card + When I select external tools from the menu + When I click on the tool configuration selection + Then I do not see tool 'CY Test Tool 2' in the tool selection + # Teacher adds a activated tool + When I click on the tool configuration selection + When I select the tool 'CY Test Tool 1' from available tools + Then I see tool 'CY Test Tool 1' is selected + When I click on save external tool button + Then I see an external tool element with tool 'CY Test Tool 1' + + # Admin deactivates an existing tool + Given I am logged in as a '' at '' + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + Then I see the tool 'CY Test Tool 1' in external tools table + When I click on edit button of tool 'CY Test Tool 1' + Then I see the external tools configuration page + Then I see the external tool configuration page title + Then I see the tool configuration infotext + Then I see tool 'CY Test Tool 1' is selected + When I deactivate the tool + Then I see the deactivate checkbox is 'checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' is deactivated in external tools table + + # Teacher sees that a tool is marked as deactivated in board + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on card Course Board + Then I see the page Course Board details + Then I see an external tool element with tool 'CY Test Tool 1' + Then I see an external tool element with tool 'CY Test Tool 1' is marked as deactivated + # Teacher tries to launch a deactivated tool + When I click on external tool element with tool 'CY Test Tool 1' + # Then nothing should happen + + # Student sees that a tool is marked as deactivated in board + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I go to the tab contents in course detail page + When I click on card Course Board + Then I see the page Course Board details + Then I see an external tool element with tool 'CY Test Tool 1' + Then I see an external tool element with tool 'CY Test Tool 1' is marked as deactivated + # Student tries to launch a deactivated tool + When I click on external tool element with tool 'CY Test Tool 1' + # Then nothing should happen + + # Admin activates existing deactivated tools + Given I am logged in as a '' at '' + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + Then I see the tool 'CY Test Tool 1' in external tools table + When I click on edit button of tool 'CY Test Tool 1' + Then I see the external tools configuration page + Then I see tool 'CY Test Tool 1' is selected + When I activate the tool + Then I see the deactivate checkbox is 'not checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' is active in tools table + Then I see the tool 'CY Test Tool 2' in external tools table + When I click on edit button of tool 'CY Test Tool 2' + Then I see the tool configuration infotext + Then I see tool 'CY Test Tool 2' is selected + When I activate the tool + Then I see the deactivate checkbox is 'not checked' + When I click on save external tool button + Then I see the tool 'CY Test Tool 2' in external tools table + Then I see the tool 'CY Test Tool 2' is active in tools table + + # Teacher adds activated tool to a board + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on card Course Board + Then I see the page Course Board details + Then I see an external tool element with tool 'CY Test Tool 1' + Then I see an external tool element with tool 'CY Test Tool 1' is not marked as deactivated + When I click on three dot menu in the card + When I select the option Edit in three dot menu on the card + When I click on plus icon to add content into card + When I select external tools from the menu + When I click on the tool configuration selection + When I select the tool 'CY Test Tool 2' from available tools + Then I see tool 'CY Test Tool 2' is selected + When I click on save external tool button + Then I see an external tool element with tool 'CY Test Tool 2' + + # Student sees activated tools in board + Given I am logged in as a '' at '' + When I go to courses overview + When I go to course 'Cypress Test Course' + Then I see course page 'Cypress Test Course' + When I click on card Course Board + Then I see the page Course Board details + Then I see an external tool element with tool 'CY Test Tool 1' + Then I see an external tool element with tool 'CY Test Tool 1' is not marked as deactivated + Then I see an external tool element with tool 'CY Test Tool 2' + Then I see an external tool element with tool 'CY Test Tool 2' is not marked as deactivated + + # Post-condition: Admin deletes course + Given I am logged in as a '' at '' + When I click on administration in menu + When I go to course administration page + When I click the delete button for course 'Cypress Test Course' in course table + Then I see the delete modal + When I click the confirmation button on the delete modal + Then I do not see course 'Cypress Test Course' in course table + + # Post-condition: Admin deletes external tools + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool 1' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table + When I click on delete button of tool 'CY Test Tool 2' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 2' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | student | namespace | fullname_teacher | fullname_student | + | admin1_nbc | teacher1_nbc | student1_nbc | nbc | Karl Herzog | Herbert Kraft | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/e2e/mediashelf/contextRestrictionOfCtlToolsInMediaShelf.feature b/cypress/e2e/mediashelf/contextRestrictionOfCtlToolsInMediaShelf.feature new file mode 100644 index 00000000..d16a4bd8 --- /dev/null +++ b/cypress/e2e/mediashelf/contextRestrictionOfCtlToolsInMediaShelf.feature @@ -0,0 +1,84 @@ +@regression_test +@stable_test +Feature: Media Shelf - Restrict CTL tools to context media-board + + As a teacher I want to add ctl tools with context restriction media-board + + @stable_test + Scenario: Teacher sees tools with context restriction media-board in the media shelf + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' + + # Pre-condition: Admin adds external tools to school + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + When I click the add external tool button + When I select the tool 'CY Test Tool 1' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 1' in external tools table has no context restriction + When I click the add external tool button + When I select the tool 'CY Test Tool Course Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Course Restriction' in external tools table + Then I see the tool 'CY Test Tool Course Restriction' in external tools table has context restriction 'Kurs-Tools' + When I click the add external tool button + When I select the tool 'CY Test Tool Board-Element Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table + Then I see the tool 'CY Test Tool Board-Element Restriction' in external tools table has context restriction 'Bereiche' + When I click the add external tool button + When I select the tool 'CY Test Tool Media-Board Restriction' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table + Then I see the tool 'CY Test Tool Media-Board Restriction' in external tools table has context restriction 'Medienregal' + When I click the add external tool button + When I select the tool 'CY Test Tool All Restrictions' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool All Restrictions' in external tools table + Then I see the tool 'CY Test Tool All Restrictions' in external tools table has context restriction 'Kurs-Tools, Bereiche, Medienregal' + When I click the add external tool button + + # Teacher sees tools with context restriction media-board in the media-shelf + Given I am logged in as a '' at '' + When I go to media shelf + Then I see the media shelf page title + Then I see the available media line + Then I see 3 tools in the available media line + Then I see tool 'CY Test Tool 1' in the available media line + Then I see tool 'CY Test Tool Media-Board Restriction' in the available media line + Then I see tool 'CY Test Tool All Restrictions' in the available media line + Then I do not see tool 'CY Test Tool Course Restriction' in the available media line + Then I do not see tool 'CY Test Tool Board-Element Restriction' in the available media line + + # Post-condition: Admin deletes external tools + Given I am logged in as a '' at '' + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool 1' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table + When I click on delete button of tool 'CY Test Tool Course Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Course Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool Board-Element Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Board-Element Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool Media-Board Restriction' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool Media-Board Restriction' in external tools table + When I click on delete button of tool 'CY Test Tool All Restrictions' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool All Restrictions' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | namespace | + | admin1_nbc | teacher1_nbc | nbc | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/e2e/mediashelf/deactivationOfCtlToolsInMediaShelf.feature b/cypress/e2e/mediashelf/deactivationOfCtlToolsInMediaShelf.feature index e3e08aa6..00ad2194 100644 --- a/cypress/e2e/mediashelf/deactivationOfCtlToolsInMediaShelf.feature +++ b/cypress/e2e/mediashelf/deactivationOfCtlToolsInMediaShelf.feature @@ -11,7 +11,6 @@ Feature: Deactivation of ctl tools in media shelf Given I am logged in as a '' at '' # Admin adds a tool - Given I am logged in as a '' at '' When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel @@ -118,8 +117,11 @@ Feature: Deactivation of ctl tools in media shelf Then I see the external tools table When I click on delete button of tool 'CY Test Tool 1' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table When I click on delete button of tool 'CY Test Tool 2' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 2' in external tools table + Then I see the external tools table is empty @staging_test Examples: diff --git a/cypress/e2e/mediashelf/noAvailableToolsInMediaShelf.feature b/cypress/e2e/mediashelf/noAvailableToolsInMediaShelf.feature index a8b26b00..9e4f2dd2 100644 --- a/cypress/e2e/mediashelf/noAvailableToolsInMediaShelf.feature +++ b/cypress/e2e/mediashelf/noAvailableToolsInMediaShelf.feature @@ -2,14 +2,14 @@ @stable_test Feature: No available tools in media shelf - As a User I want to see the no longer available chip on media element in media shelf + As a user I want to see the no longer available chip on media element in media shelf @stable_test Scenario Outline: User sees no longer available chip on media element in media shelf + Given I am logged in as a '' at '' Given I am logged in as a '' at '' - # Pre-condition: admin adds a tool - Given I am logged in as a '' at '' + # Pre-condition: Admin adds a tool When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel @@ -23,7 +23,8 @@ Feature: No available tools in media shelf When I click on save external tool button Then I see the tool 'CY Test Tool 1' in external tools table - # Admin moves tool in first media line + # Teacher moves tool in first media line + Given I am logged in as a '' at '' When I go to media shelf Then I see the media shelf page title Then I see the available media line @@ -34,15 +35,18 @@ Feature: No available tools in media shelf Then I see tool 'CY Test Tool 1' in the first media line # Admin deletes tool + Given I am logged in as a '' at '' When I click on administration in menu When I navigate to new school admin page via sub menu When I click on external tools panel Then I see the external tools table When I click on delete button of tool 'CY Test Tool 1' When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table Then I see the external tools table is empty - # Teacher sees no longer available chip on media element + # Teacher sees 'no longer available' chip on media element + Given I am logged in as a '' at '' When I go to media shelf Then I see the media shelf page title Then I see tool 'CY Test Tool 1' in the first media line @@ -56,11 +60,10 @@ Feature: No available tools in media shelf Then I see the first media line has been deleted Then I see the no available media infotext - @staging_test Examples: - | admin | namespace | - | admin1_nbc | nbc | + | admin | teacher | namespace | + | admin1_nbc | teacher1_nbc | nbc | # @school_api_test # This feature is not executable with the school_api \ No newline at end of file diff --git a/cypress/e2e/mediashelf/useMediaShelf.feature b/cypress/e2e/mediashelf/useMediaShelf.feature index 6ea26dfb..ee47454d 100644 --- a/cypress/e2e/mediashelf/useMediaShelf.feature +++ b/cypress/e2e/mediashelf/useMediaShelf.feature @@ -1,149 +1,150 @@ -@unstable_test +@regression_test +@stable_test Feature: Media Shelf - To show media shelf with respective functionality - As an teacher I want to use the media shelf + As a teacher I want to use the media shelf - @unstable_test - Scenario: Pre-test: Admin adds external tools to school - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - When I click the add external tool button - When I select the tool 'CY Test Tool 1' from available tools - When I click on save external tool button - When I click the add external tool button - When I select the tool 'CY Test Tool 2' from available tools - When I click on save external tool button - Then I see the tool 'CY Test Tool 1' in external tools table - Then I see the tool 'CY Test Tool 2' in external tools table + @stable_test + Scenario: Teacher uses the media shelf + Given I am logged in as a '' at '' + Given I am logged in as a '' at '' - @unstable_test - Scenario: Teacher opens media shelf - Given I am logged in as a 'teacher1_nbc' at 'nbc' - When I go to media shelf - Then I see the media shelf page title - Then I see the available media line - Then I see 2 tools in the available media line - Then I see tool 'CY Test Tool 1' in the available media line - Then I see tool 'CY Test Tool 2' in the available media line - Then I see the thumbnail, title and description of media element 'CY Test Tool 1' - When I click on grid layout button - Then I see the grid layout - When I click on list layout button - Then I see the list layout - # Teachers tests available media line - When I click on collapse available media line button - Then I see the available media line is collapsed - When I click on collapse available media line button - Then I see the available media line is not collapsed - When I click on three dot menu button on available media line - Then I see the available media line menu - When I click on color picker button - Then I see the available background colors - When I select the background color - Then I see the available media line has background color 'rgb(251, 233, 231)' - # Teachers tests first media line - When I click add media line button - Then I see the first media line - When I double click on the title of the first median line - When I edit the title of the first median line to 'Test Abschnitt' - Then I see the first media line with title 'Test Abschnitt' - When I click the collapse button on the first media line - Then I see the first media line is collapsed - When I click the collapse button on the first media line - Then I see the first media line is not collapsed - When I click the three dot menu button on the first media line - Then I see the media line menu - When I click on edit title button - When I edit the title of the first median line to 'Favoriten' - Then I see the first media line with title 'Favoriten' - When I click the three dot menu button on the first media line - Then I see the media line menu - When I click on color picker button - Then I see the available background colors - When I select the background color - Then I see the first media line has background color 'rgb(251, 233, 231)' - When I click the three dot menu button on the first media line - Then I see the media line menu - When I click on delete media line button - Then I see the first media line has been deleted + # Pre-condition: Admin adds external tools to school + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + When I click the add external tool button + When I select the tool 'CY Test Tool 1' from available tools + When I click on save external tool button + When I click the add external tool button + When I select the tool 'CY Test Tool 2' from available tools + When I click on save external tool button + Then I see the tool 'CY Test Tool 1' in external tools table + Then I see the tool 'CY Test Tool 2' in external tools table - # Test Drag & Drop in media shelf - # Drag & Drop tool in new Line - When I move tool 'CY Test Tool 1' in to ghost media line - Then I see the first media line - Then I see tool 'CY Test Tool 1' in the first media line - # Launch tool in available media line - When I launch tool 'CY Test Tool 2' in the available media line with given url 'https://google.com/' - Then I see tool 'CY Test Tool 2' on media element was launched - # Launch tool in first media line - When I launch tool 'CY Test Tool 1' in the first media line with given url 'https://google.com/' - Then I see tool 'CY Test Tool 1' on media element was launched - # Drag & Drop tool from one line to another line - When I move tool 'CY Test Tool 2' in the first media line - Then I see tool 'CY Test Tool 2' in the first media line - # Drag & Drop tool in available line - When I move tool 'CY Test Tool 2' to the empty available media line - Then I see tool 'CY Test Tool 2' in the available media line - # Delete line with tool - When I click the three dot menu button on the first media line - Then I see the media line menu - When I click on delete media line button - Then I see the first media line has been deleted - Then I see tool 'CY Test Tool 1' in the available media line - Then I see the first media line has been deleted + # Teacher opens media shelf + Given I am logged in as a '' at '' + When I go to media shelf + Then I see the media shelf page title + Then I see the available media line + Then I see 2 tools in the available media line + Then I see tool 'CY Test Tool 1' in the available media line + Then I see tool 'CY Test Tool 2' in the available media line + Then I see the thumbnail, title and description of media element 'CY Test Tool 1' + When I click on grid layout button + Then I see the grid layout + When I click on list layout button + Then I see the list layout - When I move tool 'CY Test Tool 1' in to ghost media line - Then I see the first media line - Then I see tool 'CY Test Tool 1' in the first media line - When I move tool 'CY Test Tool 2' in the first media line - Then I see tool 'CY Test Tool 2' in the first media line + # Teacher tests available media line + When I click on collapse available media line button + Then I see the available media line is collapsed + When I click on collapse available media line button + Then I see the available media line is not collapsed + When I click on three dot menu button on available media line + Then I see the available media line menu + When I click on color picker button + Then I see the available background colors + When I select the background color + Then I see the available media line has background color 'rgb(251, 233, 231)' - # Teacher deletes tool - When I click the three dot menu button on media element 'CY Test Tool 1' - When I click on delete media element button - Then I see delete media element dialog - When I click confirm delete media element button - Then I see tool 'CY Test Tool 1' in the available media line + # Teacher tests first media line + When I click add media line button + Then I see the first media line + When I double click on the title of the first median line + When I edit the title of the first median line to 'Test Abschnitt' + Then I see the first media line with title 'Test Abschnitt' + When I click the collapse button on the first media line + Then I see the first media line is collapsed + When I click the collapse button on the first media line + Then I see the first media line is not collapsed + When I click the three dot menu button on the first media line + Then I see the media line menu + When I click on edit title button + When I edit the title of the first median line to 'Favoriten' + Then I see the first media line with title 'Favoriten' + When I click the three dot menu button on the first media line + Then I see the media line menu + When I click on color picker button + Then I see the available background colors + When I select the background color + Then I see the first media line has background color 'rgb(251, 233, 231)' + When I click the three dot menu button on the first media line + Then I see the media line menu + When I click on delete media line button + Then I see the first media line has been deleted - # Deleting a tool from another location - # Admin deletes tool from school admin page - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table - When I click on delete button of tool 'CY Test Tool 2' - When I confirm deletion on deletion dialog - # Teachers removes deleted media element placeholder - Given I am logged in as a 'teacher1_nbc' at 'nbc' - When I go to media shelf - Then I see the no longer available chip on media element 'CY Test Tool 2' - When I click the three dot menu button on media element 'CY Test Tool 2' - When I click on delete media element button - Then I see delete media element dialog - When I click confirm delete media element button - Then I do not see tool 'CY Test Tool 2' in the available media line + # Test Drag & Drop in media shelf + # Teacher drags & drops tool in new Line + When I move tool 'CY Test Tool 1' in to ghost media line + Then I see the first media line + Then I see tool 'CY Test Tool 1' in the first media line - # Post Test: Reset Media Shelf - When I click the three dot menu button on the first media line - Then I see the media line menu - When I click on delete media line button - Then I see the first media line has been deleted - When I click on three dot menu button on available media line - Then I see the available media line menu - When I click on color picker button - Then I see the available background colors - When I select default line color - Then I see the available media line has background color 'rgb(255, 255, 255)' + # Teacher launches tool in available media line + When I launch tool 'CY Test Tool 2' in the available media line with given url 'https://google.com/' + Then I see tool 'CY Test Tool 2' on media element was launched + # Teacher launches tool in first media line + When I launch tool 'CY Test Tool 1' in the first media line with given url 'https://google.com/' + Then I see tool 'CY Test Tool 1' on media element was launched - @unstable_test - Scenario: Post-test: Admin deletes external tools - Given I am logged in as a 'admin1_nbc' at 'nbc' - When I click on administration in menu - When I navigate to new school admin page via sub menu - When I click on external tools panel - Then I see the external tools table - When I click on delete button of tool 'CY Test Tool 1' - When I confirm deletion on deletion dialog + # Teacher drags & drops tool from one line to another line + When I move tool 'CY Test Tool 2' in the first media line + Then I see tool 'CY Test Tool 2' in the first media line + # Teacher drags & drops tool in available line + When I move tool 'CY Test Tool 2' to the empty available media line + Then I see tool 'CY Test Tool 2' in the available media line + + # Teacher deletes line with tool + When I click the three dot menu button on the first media line + Then I see the media line menu + When I click on delete media line button + Then I see the first media line has been deleted + Then I see tool 'CY Test Tool 1' in the available media line + Then I see the first media line has been deleted + + # Teacher deletes tool + When I move tool 'CY Test Tool 1' in to ghost media line + Then I see the first media line + Then I see tool 'CY Test Tool 1' in the first media line + When I move tool 'CY Test Tool 2' in the first media line + Then I see tool 'CY Test Tool 2' in the first media line + When I click the three dot menu button on media element 'CY Test Tool 1' + When I click on delete media element button + Then I see delete media element dialog + When I click confirm delete media element button + Then I see tool 'CY Test Tool 1' in the available media line + + # Post-condition: Teacher resets media shelf + When I click the three dot menu button on the first media line + Then I see the media line menu + When I click on delete media line button + Then I see the first media line has been deleted + Then I see tool 'CY Test Tool 2' in the available media line + When I click on three dot menu button on available media line + Then I see the available media line menu + When I click on color picker button + Then I see the available background colors + When I select default line color + Then I see the available media line has background color 'rgb(255, 255, 255)' + + # Post-condition: Admin deletes external tools + Given I am logged in as a '' at '' + When I click on administration in menu + When I navigate to new school admin page via sub menu + When I click on external tools panel + Then I see the external tools table + When I click on delete button of tool 'CY Test Tool 1' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 1' in external tools table + When I click on delete button of tool 'CY Test Tool 2' + When I confirm deletion on deletion dialog + Then I do not see the tool 'CY Test Tool 2' in external tools table + Then I see the external tools table is empty + + @staging_test + Examples: + | admin | teacher | namespace | + | admin1_nbc | teacher1_nbc | nbc | + + # @school_api_test + # This feature is not executable with the school_api diff --git a/cypress/support/pages/admin/pageAdministration.js b/cypress/support/pages/admin/pageAdministration.js index 06994c73..9de96ba8 100644 --- a/cypress/support/pages/admin/pageAdministration.js +++ b/cypress/support/pages/admin/pageAdministration.js @@ -1018,7 +1018,7 @@ class Management { insertToolLink(toolLink) { cy.get(Management.#toolSelection).click().type(toolLink); - cy.get(Management.#toolConfigurationSelectItem).contains("OpenStreetMap").click(); + cy.get(Management.#toolConfigurationSelectItem).contains("CY Test Tool OpenStreetMap").click(); } checkConfiguration(key, value) { diff --git a/cypress/support/pages/course_board/pageBoard.js b/cypress/support/pages/course_board/pageBoard.js index 4ac04c31..6b1b206c 100644 --- a/cypress/support/pages/course_board/pageBoard.js +++ b/cypress/support/pages/course_board/pageBoard.js @@ -256,7 +256,7 @@ class Board { clickThreeDotMenuOnExternalToolElementWithTool(toolName) { cy.get(`[data-testid="board-external-tool-element-${toolName}"]`) - .find('[data-testid="board-menu-button"]') + .find('[data-testid*="element-menu-button"]') .click(); }