Skip to content

Commit

Permalink
Fix for issue sectiontext qtype (label) should NOT support feedback
Browse files Browse the repository at this point in the history
Signed-off-by: Joseph Rézeau <[email protected]>
  • Loading branch information
rezeau authored and mchurchward committed Feb 23, 2024
1 parent e8607f8 commit d450fd6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions classes/question/sectiontext.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function required() {
* True if question type supports feedback options. False by default.
*/
public function supports_feedback() {
return true;
return false;
}

/**
Expand All @@ -70,7 +70,7 @@ public function supports_feedback_scores() {
* True if the question supports feedback and has valid settings for feedback. Override if the default logic is not enough.
*/
public function valid_feedback() {
return true;
return false;
}

/**
Expand Down
8 changes: 4 additions & 4 deletions tests/behat/no_feedback_question_types.feature
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ Feature: In questionnaire, certain questions will not activate feedback options.
And I log in as "teacher1"
And I am on "Course 1" course homepage
And I follow "Test questionnaire"
And I navigate to "Advanced settings" in current page administration
Then I should not see "Feedback options"
And I navigate to "Feedback" in current page administration
Then I should not see "Display Scores"
And I follow "Questions"
Then I should see "Add questions"
And I add a "Check Boxes" question and I fill the form with:
Expand Down Expand Up @@ -62,6 +62,6 @@ Feature: In questionnaire, certain questions will not activate feedback options.
| Max. text length | 15 |
| Question Text | Enter some text |
Then I should see "[Text Box] (Q8)"
And I follow "Advanced settings"
And I should not see "Feedback options"
And I follow "Feedback"
And I should not see "Display Scores"
And I log out

0 comments on commit d450fd6

Please sign in to comment.