Skip to content

Conversation

@mtyaka
Copy link
Member

@mtyaka mtyaka commented Apr 12, 2016

When the pb_mcq_hide_previous_answer is set to True, question-level feedback should not be displayed when user returns to the page.

cf. MCKIN-3999

Test Instructions

  1. Create a new subunit containing one problem builder MRQ question unit, and another arbitrary unit. Make sure to put some content into the "Message (General feedback provided when submitting)" field of the MRQ.
  2. Enable pb_mcq_hide_previous_answer in your XBLOCK_SETTINGS.
  3. Go to the unit with the MRQ question, fill it in, and submit. You should see the general feedback message.
  4. Go to the next unit, then come back to the unit with the MRQ question.
  5. General feedback message should be hidden.

@mtyaka mtyaka force-pushed the hide-mrq-feedback branch from 62d826e to 484e428 Compare April 12, 2016 08:29
# has a question level feedback. This feedback should also be suppressed.
("feedback_persistence_mcq_no_tips.xml", '.feedback')
("feedback_persistence_mcq_no_tips.xml", '.feedback'),
("feedback_persistence_mrq_no_tips.xml", '.feedback'),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mtyaka I think it would be worth extending this test to also cover cases where an MCQ/MRQ has:

  • no question-level feedback and no choice-level feedback (no message displayed when clicking checkmark for individual choice after submitting answer)
  • both question-level feedback and choice-level (general message displayed after submitting, choice-level message displayed after clicking corresponding checkmark)

Aside from making the code even more robust against regressions, a test that covers all combinations could also serve to document the expected behavior for us.

@itsjeyd
Copy link
Member

itsjeyd commented Apr 12, 2016

@mtyaka Works for me! Tested on both LMS and Apros (thanks for the course export).

Aside from the comment I left about the integration tests, maybe we should add a comment to the code that explains that pb_mcq_hide_previous_answer also controls previous answers for MRQs. This line would be a good place for such a comment I think.

@mtyaka mtyaka force-pushed the hide-mrq-feedback branch from 484e428 to a02dfe5 Compare April 13, 2016 08:01
@mtyaka
Copy link
Member Author

mtyaka commented Apr 13, 2016

@itsjeyd Thanks for the good suggestions! I implemented the changes, please take another look.

@@ -0,0 +1,11 @@
<vertical_demo>
<problem-builder url_name="mcq_general_feedback" enforce_dependency="false">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mtyaka Nit: Can we do without enforce_dependency="false" in the templates that are used by test_feedback_persistence_tips? It seems to be redundant since enforce_dependency has a default value of False.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @itsjeyd, I removed enforce_dependency. It was redundant indeed.

@itsjeyd
Copy link
Member

itsjeyd commented Apr 13, 2016

@mtyaka Looking great, thanks for the updates! I had one more nit (sorry for not noticing sooner), but other than that this is 👍

When the pb_mcq_hide_previous_answer is set to True, question-level
feedback should not be displayed when user returns to the page.
@mtyaka mtyaka force-pushed the hide-mrq-feedback branch from a02dfe5 to ea3924a Compare April 13, 2016 12:58
@mtyaka mtyaka merged commit 527671f into master Apr 13, 2016
@mtyaka mtyaka deleted the hide-mrq-feedback branch April 13, 2016 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants