Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for issue sectiontext qtype (label) should NOT support feedback #547

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading