From 6c7f570e14acf9328154cf86218e1e959862d7fe Mon Sep 17 00:00:00 2001 From: Simey Lameze Date: Mon, 15 Aug 2022 12:22:43 +0800 Subject: [PATCH] MDL-75923 tool_usertours: Update tour content to match formatted content When an HTML content area contains invalid HTML, some editors will clean and validate the content upon submission. In this case the content was: Test content But this should be wrapped in some form of container which accepts phrasing content (such as a

tag). Some editors, such as TinyMCE, will normalise the content and add the wrapping paragraph tags to it. Furthermore, the bold tag is purely stylistic and does not have semantic meaning. As a result, the tag is favoured and some editors, again such as TinyMCE, will replace bold tags with strong tags. We should update the content here to be valid HTML (wrap the bold tag in a para), and use a strong tag rather than bold. This allows this test to pass both with Atto, and other stricter editors such as TinyMCE 6. --- admin/tool/usertours/tests/behat/tour_content_type.feature | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/tool/usertours/tests/behat/tour_content_type.feature b/admin/tool/usertours/tests/behat/tour_content_type.feature index a2e15329abb..102fcef3fa6 100644 --- a/admin/tool/usertours/tests/behat/tour_content_type.feature +++ b/admin/tool/usertours/tests/behat/tour_content_type.feature @@ -58,7 +58,7 @@ Feature: Apply content type to a tour And I click on "New step" "link" And I set the field "Title" to "tour_activityinfo_course_teacher_title,tool_usertours" And I select "Manual" from the "Content type" singleselect - And I set the field "id_content" to "Test content" + And I set the field "id_content" to "

Test content

" And I press "Save changes" And I should see "New: Activity information" And I should see "Test content" @@ -66,7 +66,7 @@ Feature: Apply content type to a tour And I should see "Editing \"New: Activity information\"" And I should not see "Language string ID" in the "#fitem_id_contentlangstring" "css_element" And the field "Title" matches value "tour_activityinfo_course_teacher_title,tool_usertours" - And the field "id_content" matches value "Test content" + And the field "id_content" matches value "

Test content

" @javascript Scenario: Tour name and description can be translatable