From 6dc10b6241f3ca3f06a80a92d5571f7c528b23d3 Mon Sep 17 00:00:00 2001 From: David Woloszyn Date: Thu, 5 Jan 2023 12:11:42 +1100 Subject: [PATCH] MDL-76607 timeline: Reordered message to account for long course name --- .../templates/event-list-item.mustache | 2 +- .../tests/behat/block_timeline_dates.feature | 36 +++++++++---------- 2 files changed, 19 insertions(+), 19 deletions(-) diff --git a/blocks/timeline/templates/event-list-item.mustache b/blocks/timeline/templates/event-list-item.mustache index a28588cd102..7c442c13075 100644 --- a/blocks/timeline/templates/event-list-item.mustache +++ b/blocks/timeline/templates/event-list-item.mustache @@ -79,7 +79,7 @@ {{activitystr}} {{/courseview}} {{^courseview}} - {{#course.fullnamedisplay}}{{{course.fullnamedisplay}}} · {{/course.fullnamedisplay}}{{activitystr}} + {{activitystr}}{{#course.fullnamedisplay}} · {{{course.fullnamedisplay}}}{{/course.fullnamedisplay}} {{/courseview}} diff --git a/blocks/timeline/tests/behat/block_timeline_dates.feature b/blocks/timeline/tests/behat/block_timeline_dates.feature index 234764be6a5..681fd1aad06 100644 --- a/blocks/timeline/tests/behat/block_timeline_dates.feature +++ b/blocks/timeline/tests/behat/block_timeline_dates.feature @@ -39,23 +39,23 @@ Feature: The timeline block allows users to see upcoming activities And I click on "Filter timeline by date" "button" in the "Timeline" "block" When I click on "Next 7 days" "link" in the "Timeline" "block" Then "Test choice 1" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Choice closes" in the "Timeline" "block" + And I should see "Choice closes · Course 2" in the "Timeline" "block" And "Test feedback 1" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 2" in the "Timeline" "block" And "Test assign 2" "link" should exist in the "Timeline" "block" And "Test feedback 4" "link" should exist in the "Timeline" "block" And "Test choice 2" "link" should not exist in the "Timeline" "block" And "Test choice 3" "link" should not exist in the "Timeline" "block" And "Test feedback 3" "link" should not exist in the "Timeline" "block" And "Test assign 1" "link" should not exist in the "Timeline" "block" - And I should not see "Course 1 · Assignment is due" in the "Timeline" "block" + And I should not see "Assignment is due · Course 1" in the "Timeline" "block" Scenario: Overdue in date view Given I log in as "student1" And I click on "Filter timeline by date" "button" in the "Timeline" "block" When I click on "Overdue" "link" in the "Timeline" "block" Then "Test assign 1" "link" should exist in the "Timeline" "block" - And I should see "Course 1 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 1" in the "Timeline" "block" And "Test assign 2" "link" should exist in the "Timeline" "block" And "Test choice 2" "link" should not exist in the "Timeline" "block" And "Test feedback 1" "link" should not exist in the "Timeline" "block" @@ -69,20 +69,20 @@ Feature: The timeline block allows users to see upcoming activities And I click on "Filter timeline by date" "button" in the "Timeline" "block" When I click on "All" "link" in the "Timeline" "block" Then "Test assign 1" "link" should exist in the "Timeline" "block" - And I should see "Course 1 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 1" in the "Timeline" "block" And "Test assign 2" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 2" in the "Timeline" "block" And "Test feedback 1" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 2" in the "Timeline" "block" And "Test choice 1" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Choice closes" in the "Timeline" "block" + And I should see "Choice closes · Course 2" in the "Timeline" "block" And "Test feedback 4" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 2" in the "Timeline" "block" And "Test choice 2" "link" should not exist in the "Timeline" "block" And "Test feedback 2" "link" should not exist in the "Timeline" "block" And I click on "Show more activities" "button" And "Test feedback 2" "link" should exist in the "Timeline" "block" - And I should see "Course 1 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 1" in the "Timeline" "block" And "Test choice 3" "link" should exist in the "Timeline" "block" And I should see "Test assign 1" in the "Timeline" "block" And I should see "Test feedback 1" in the "Timeline" "block" @@ -97,20 +97,20 @@ Feature: The timeline block allows users to see upcoming activities When I click on "All" "link" in the "Timeline" "block" And I reload the page Then "Test assign 1" "link" should exist in the "Timeline" "block" - And I should see "Course 1 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 1" in the "Timeline" "block" And "Test assign 2" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 2" in the "Timeline" "block" And "Test feedback 1" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 2" in the "Timeline" "block" And "Test choice 1" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Choice closes" in the "Timeline" "block" + And I should see "Choice closes · Course 2" in the "Timeline" "block" And "Test feedback 4" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 2" in the "Timeline" "block" And I should not see "Test choice 2" in the "Timeline" "block" And I should not see "Test feedback 2" in the "Timeline" "block" And I click on "Show more activities" "button" And "Test feedback 2" "link" should exist in the "Timeline" "block" - And I should see "Course 1 · Feedback closes" in the "Timeline" "block" + And I should see "Feedback closes · Course 1" in the "Timeline" "block" And I should see "Test assign 1" in the "Timeline" "block" And I should see "Test feedback 1" in the "Timeline" "block" And I should see "Test feedback 3" in the "Timeline" "block" @@ -124,9 +124,9 @@ Feature: The timeline block allows users to see upcoming activities When I click on "Overdue" "link" in the "Timeline" "block" And I reload the page Then "Test assign 1" "link" should exist in the "Timeline" "block" - And I should see "Course 1 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 1" in the "Timeline" "block" And "Test assign 2" "link" should exist in the "Timeline" "block" - And I should see "Course 2 · Assignment is due" in the "Timeline" "block" + And I should see "Assignment is due · Course 2" in the "Timeline" "block" And "Test feedback 1" "link" should not exist in the "Timeline" "block" And "Test feedback 3" "link" should not exist in the "Timeline" "block" And "Test feedback 4" "link" should not exist in the "Timeline" "block"