Skip to content

Commit 7782919

Browse files
close modals before accessibility check in workflow editor tests
Four tests were failing because they left a GModal open when the @selenium_test decorator ran assert_baseline_accessibility(). When a native <dialog> is open via showModal(), the browser marks everything outside it as inert — axe-core skips those elements, making aria-roles inapplicable and failing assert_passes('aria-roles'). - test_save_as, test_editor_invalid_tool_state, test_missing_tools: close the modal after taking the screenshot - test_editor_subworkflow_tool_upgrade_message: the invalid tool state causes a save confirmation dialog to appear when saving — dismiss it
1 parent eeeca04 commit 7782919

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

lib/galaxy_test/selenium/test_workflow_editor.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -636,6 +636,7 @@ def test_save_as(self):
636636
self.screenshot("workflow_editor_edit_menu")
637637

638638
self.components.workflow_editor.save_as_activity.wait_for_and_click()
639+
self.components.workflow_editor.modal_button_close.wait_for_and_click()
639640

640641
@selenium_test
641642
def test_editor_tool_upgrade(self):
@@ -723,6 +724,7 @@ def test_editor_subworkflow_tool_upgrade_message(self):
723724
self.screenshot("workflow_editor_subworkflow_tool_upgrade")
724725
self.components.workflow_editor.modal_button_close.wait_for_and_click()
725726
self.assert_workflow_has_changes_and_save()
727+
self.components.workflow_editor.save_workflow_confirmation_button.wait_for_and_click()
726728

727729
@staticmethod
728730
def set_text_element(element, value):
@@ -1049,6 +1051,7 @@ def test_editor_invalid_tool_state(self):
10491051
self.assert_modal_has_text("Using version '0.2' instead of version '0.0.1'")
10501052
self.assert_modal_has_text("Using default: '1'")
10511053
self.screenshot("workflow_editor_invalid_state")
1054+
self.components.workflow_editor.modal_button_close.wait_for_and_click()
10521055

10531056
@selenium_test
10541057
def test_missing_tools(self):
@@ -1067,6 +1070,7 @@ def test_missing_tools(self):
10671070
self.components.workflows.edit_button.wait_for_and_click()
10681071
self.assert_modal_has_text("Tool is not installed")
10691072
self.screenshot("workflow_editor_missing_tool")
1073+
self.components.workflow_editor.modal_button_close.wait_for_and_click()
10701074

10711075
def tab_to(self, accessible_name, direction="forward"):
10721076
for _ in range(100):

0 commit comments

Comments
 (0)