When an observer changes the selected student in the picker, we check
to see whether the observer should see the k5 dashboard with the new
student selected. If they are currently seeing the wrong dashboard
type, we reload the page. Now, we'll also check what font the observer
should see with the new student selected (in the same network
request). If the dashboard type or font is incorrect, reload the page.
This situation (where an observer is observing multiple students where
some see the classic font and others see the k5 font) should be
fairly uncommon. We do not need to do the font check on the classic
dashboard page because if the user is seeing the classic dashboard,
they'll always see the classic font.
flag = k5_font_selection
closes LS-3925
Test plan:
- Create 2 accounts, one with k5+lato, one with k5+balsamiq
- Create a course in each account
- Enroll 3 students in the courses; 2 of the students in 1 course, 1
student in the other course
- Enroll an observer in both courses, link the observer to
the student(s) in each course
- Act as the observer
- Visit the dashboard
- Select one of the students in the picker
- Expect to see the appropriate font
- Select another student in the picker
- If you selected the student who sees the same font, expect the
dashboard to not reload
- If you selected the student who sees the other font, expect the
dashboard to reload and the new font to apply
Change-Id: Ie62c2c7ebc38e53fdc90402b510e4e4ecaf04fa3
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/315716
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Ed Schiebel <eschiebel@instructure.com>
Reviewed-by: Luis Oliveira <luis.oliveira@instructure.com>
QA-Review: Ed Schiebel <eschiebel@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>