From ef942cb2e7048429a5a79d1a8f6171e6f0d7a034 Mon Sep 17 00:00:00 2001 From: Stevani Andolo Date: Thu, 14 Aug 2025 14:22:59 +0800 Subject: [PATCH] MDL-82943 behat: Fix behat failures --- .../field/textarea/tests/behat/default_value.feature | 2 +- .../customfield/tests/behat/edit_fields_settings.feature | 2 +- .../tests/behat/accessibilitychecker.feature | 8 ++++---- .../tiny/plugins/autosave/tests/behat/autosave.feature | 2 +- .../lib/editor/tiny/plugins/link/tests/behat/link.feature | 4 ++-- .../mod/lesson/tests/behat/duplicate_lesson_page.feature | 6 +++--- public/mod/lesson/tests/behat/questions_images.feature | 4 ++-- .../mod/quiz/tests/behat/manually_mark_question.feature | 2 +- public/mod/workshop/tests/behat/embedded_images.feature | 6 +++--- 9 files changed, 18 insertions(+), 18 deletions(-) diff --git a/public/customfield/field/textarea/tests/behat/default_value.feature b/public/customfield/field/textarea/tests/behat/default_value.feature index a1c39c26701..a217f931985 100644 --- a/public/customfield/field/textarea/tests/behat/default_value.feature +++ b/public/customfield/field/textarea/tests/behat/default_value.feature @@ -37,7 +37,7 @@ Feature: Default value for the textarea custom field can contain images And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "gd-logo.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "Example" + And I set the field "How would you describe this image to someone who cannot see it?" to "Example" And I click on "Save" "button" in the "Image details" "dialogue" And I click on "Save changes" "button" in the "Adding a new Text area" "dialogue" And I log out diff --git a/public/customfield/tests/behat/edit_fields_settings.feature b/public/customfield/tests/behat/edit_fields_settings.feature index f66b7e7f354..977ff899022 100644 --- a/public/customfield/tests/behat/edit_fields_settings.feature +++ b/public/customfield/tests/behat/edit_fields_settings.feature @@ -83,7 +83,7 @@ Feature: Teachers can edit course custom fields And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "gd-logo.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "Example" + And I set the field "How would you describe this image to someone who cannot see it?" to "Example" And I click on "Save" "button" in the "Image details" "dialogue" And I click on "Save changes" "button" in the "Updating Field 1" "dialogue" And I log out diff --git a/public/lib/editor/tiny/plugins/accessibilitychecker/tests/behat/accessibilitychecker.feature b/public/lib/editor/tiny/plugins/accessibilitychecker/tests/behat/accessibilitychecker.feature index f5cc262e80a..f3fb6e397ca 100644 --- a/public/lib/editor/tiny/plugins/accessibilitychecker/tests/behat/accessibilitychecker.feature +++ b/public/lib/editor/tiny/plugins/accessibilitychecker/tests/behat/accessibilitychecker.feature @@ -28,8 +28,8 @@ Feature: Tiny editor accessibility checker And I click on "View" "link" in the "Accessibility checker" "dialogue" And I click on the "Image" button for the "Description" TinyMCE editor And I wait "1" seconds - And I click on "This image is decorative only" "checkbox" - And I set the field "How would you describe this image to someone who can't see it?" to "No more warning!" + And I click on "Decorative image" "checkbox" + And I set the field "How would you describe this image to someone who cannot see it?" to "No more warning!" And I press "Save" And I click on the "Tools > Accessibility checker" menu item for the "Description" TinyMCE editor And I should see "Congratulations, no accessibility issues found!" in the "Accessibility checker" "dialogue" @@ -39,8 +39,8 @@ Feature: Tiny editor accessibility checker And I set the field "URL" to "http://download.moodle.org/unittest/test.jpg" And I click on "Add" "button" in the "Insert image" "dialogue" And I wait "1" seconds - And I set the field "How would you describe this image to someone who can't see it?" to "" - And I click on "This image is decorative only" "checkbox" + And I set the field "How would you describe this image to someone who cannot see it?" to "" + And I click on "Decorative image" "checkbox" When I press "Save" And I click on the "Tools > Accessibility checker" menu item for the "Description" TinyMCE editor Then I should see "Congratulations, no accessibility issues found!" in the "Accessibility checker" "dialogue" diff --git a/public/lib/editor/tiny/plugins/autosave/tests/behat/autosave.feature b/public/lib/editor/tiny/plugins/autosave/tests/behat/autosave.feature index ff1a3d1500f..d7b2f0aebb0 100644 --- a/public/lib/editor/tiny/plugins/autosave/tests/behat/autosave.feature +++ b/public/lib/editor/tiny/plugins/autosave/tests/behat/autosave.feature @@ -45,7 +45,7 @@ Feature: Tiny editor autosave And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "tinyscreenshot.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the Moodle" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the Moodle" And I click on "Save" "button" in the "Image details" "dialogue" And I click on "Save and display" "button" When I am on the "Course 1" course page logged in as teacher1 diff --git a/public/lib/editor/tiny/plugins/link/tests/behat/link.feature b/public/lib/editor/tiny/plugins/link/tests/behat/link.feature index 40e17848cd8..bdc7315d46e 100644 --- a/public/lib/editor/tiny/plugins/link/tests/behat/link.feature +++ b/public/lib/editor/tiny/plugins/link/tests/behat/link.feature @@ -107,7 +107,7 @@ Feature: Add links to TinyMCE And I select "Private files" repository in file picker And I click on "moodle-logo.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the Moodle" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the Moodle" And I click on "Save" "button" in the "Image details" "dialogue" And I select the "img" element in position "0" of the "Description" TinyMCE editor And I click on the "Link" button for the "Description" TinyMCE editor @@ -129,7 +129,7 @@ Feature: Add links to TinyMCE And I click on "Edit profile" "link" in the "region-main" "region" And I select the "img" element in position "0" of the "Description" TinyMCE editor And I click on the "Image" button for the "Description" TinyMCE editor - And the field "How would you describe this image to someone who can't see it?" matches value "It's the Moodle" + And the field "How would you describe this image to someone who cannot see it?" matches value "It's the Moodle" And I click on "Close" "button" in the "Image details" "dialogue" And I click on the "Link" button for the "Description" TinyMCE editor And the field "Text to display" matches value "Moodle - Open-source learning platform" diff --git a/public/mod/lesson/tests/behat/duplicate_lesson_page.feature b/public/mod/lesson/tests/behat/duplicate_lesson_page.feature index 1fe950c794e..b65ff113c41 100644 --- a/public/mod/lesson/tests/behat/duplicate_lesson_page.feature +++ b/public/mod/lesson/tests/behat/duplicate_lesson_page.feature @@ -41,7 +41,7 @@ Feature: In a lesson activity, a teacher can duplicate a lesson page And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodle_logo.jpg" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the logo" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the logo" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save page" And I follow "Duplicate page: First page name" @@ -76,7 +76,7 @@ Feature: In a lesson activity, a teacher can duplicate a lesson page And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodle_logo.jpg" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the logo" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the logo" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save page" And I follow "Duplicate page: True false with an image in the answer" @@ -114,7 +114,7 @@ Feature: In a lesson activity, a teacher can duplicate a lesson page And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodle_logo.jpg" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the logo" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the logo" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save page" And I follow "Duplicate page: True false with an image in the feedback" diff --git a/public/mod/lesson/tests/behat/questions_images.feature b/public/mod/lesson/tests/behat/questions_images.feature index 39c4146842e..796dfb3b8b2 100644 --- a/public/mod/lesson/tests/behat/questions_images.feature +++ b/public/mod/lesson/tests/behat/questions_images.feature @@ -48,7 +48,7 @@ Feature: In a lesson activity, teacher can add embedded images in questions answ And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodle_logo.jpg" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the logo" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the logo" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save page" And I set the field "qtype" to "Add a question page" @@ -68,7 +68,7 @@ Feature: In a lesson activity, teacher can add embedded images in questions answ And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodle_logo.jpg" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the logo" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the logo" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save page" When I am on the "Test lesson name" "lesson activity" page logged in as student1 diff --git a/public/mod/quiz/tests/behat/manually_mark_question.feature b/public/mod/quiz/tests/behat/manually_mark_question.feature index d7ba2448d83..3c688126ed2 100644 --- a/public/mod/quiz/tests/behat/manually_mark_question.feature +++ b/public/mod/quiz/tests/behat/manually_mark_question.feature @@ -71,7 +71,7 @@ Feature: Teachers can override the grade for any question And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodle_logo.jpg" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "It's the logo" + And I set the field "How would you describe this image to someone who cannot see it?" to "It's the logo" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save" and switch to main window And I switch to the main window diff --git a/public/mod/workshop/tests/behat/embedded_images.feature b/public/mod/workshop/tests/behat/embedded_images.feature index 146e2cf2927..244b38c2ea0 100644 --- a/public/mod/workshop/tests/behat/embedded_images.feature +++ b/public/mod/workshop/tests/behat/embedded_images.feature @@ -37,7 +37,7 @@ Feature: Teachers can embed images into instructions and conclusion fields And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodlelogo.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "How to submit" + And I set the field "How would you describe this image to someone who cannot see it?" to "How to submit" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save and display" # Embed the image into Instructions for assessment. @@ -48,7 +48,7 @@ Feature: Teachers can embed images into instructions and conclusion fields And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodlelogo.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "How to assess" + And I set the field "How would you describe this image to someone who cannot see it?" to "How to assess" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save and display" # Embed the image into Conclusion. @@ -59,7 +59,7 @@ Feature: Teachers can embed images into instructions and conclusion fields And I click on "Private files" "link" in the ".fp-repo-area" "css_element" And I click on "moodlelogo.png" "link" And I click on "Select this file" "button" - And I set the field "How would you describe this image to someone who can't see it?" to "Well done" + And I set the field "How would you describe this image to someone who cannot see it?" to "Well done" And I click on "Save" "button" in the "Image details" "dialogue" And I press "Save and display" # Save the form and check the images are displayed in appropriate phases.