teammates icon indicating copy to clipboard operation
teammates copied to clipboard

[#12894] Per-recipient stats are calculated based on student name, not email

Open Hkovin opened this issue 1 year ago • 5 comments

Fixes #12894

Outline of Solution

This PR is ready for review. We solved the issue by modifying msq-question-statistics.calculation.ts. Instead of using "response.recipient" to index into perRecipientResponse we used "response.recipientEmail." We also created another variable to store the recipient names in order to populate the recipient property of the perRecipientResponses object.

Hkovin avatar Apr 04 '24 00:04 Hkovin

hi @Hkovin, thank you for the PR, do fix the failing tests before we proceed to review it, thank you!

cedricongjh avatar Apr 09 '24 09:04 cedricongjh

Currently, the component test "MsqQuestionStatisticsComponent" in the file "src/web/app/components/question-types/question-statistics/msq-question-statistics.component.spec.ts" is failing. This is due to the code changes I made, which index the recipients based on email rather than name - which was needed in order to uniquely identify students. Unfortunately, with the logic needed to resolve this issue, I won't be able to pass this test.

Hkovin avatar Apr 16 '24 14:04 Hkovin

Currently, the component test "MsqQuestionStatisticsComponent" in the file "src/web/app/components/question-types/question-statistics/msq-question-statistics.component.spec.ts" is failing. This is due to the code changes I made, which index the recipients based on email rather than name - which was needed in order to uniquely identify students. Unfortunately, with the logic needed to resolve this issue, I won't be able to pass this test.

hi @Hkovin, since you changed the logic, the tests have to change accordingly to reflect the change in logic as well, do go ahead and update the tests

cedricongjh avatar Apr 19 '24 13:04 cedricongjh

Currently, the component test "MsqQuestionStatisticsComponent" in the file "src/web/app/components/question-types/question-statistics/msq-question-statistics.component.spec.ts" is failing. This is due to the code changes I made, which index the recipients based on email rather than name - which was needed in order to uniquely identify students. Unfortunately, with the logic needed to resolve this issue, I won't be able to pass this test.

hi @Hkovin, since you changed the logic, the tests have to change accordingly to reflect the change in logic as well, do go ahead and update the tests

Hi @cedricongjh, we did attempt to change the logic in the tests, however the CI build still runs on the old tests that use the old logic.

jckras avatar Apr 22 '24 18:04 jckras

the CI will run the latest version of the tests, including those in this PR, it appears that there are not any tests in the PR, do remember to push them, thank you

cedricongjh avatar Apr 23 '24 05:04 cedricongjh

Closing due to inactivity

weiquu avatar Jun 29 '24 06:06 weiquu