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

Remove user context URL params #1195

Merged
merged 3 commits into from
Oct 30, 2024
Merged

Remove user context URL params #1195

merged 3 commits into from
Oct 30, 2024

Conversation

mwtrew
Copy link
Contributor

@mwtrew mwtrew commented Oct 21, 2024

Stops checking for stage and examBoard URL parameters when setting the user context, and stops syncing the current user context with the URL parameters.

Also refactors the user context derivation logic into a unit-testable function, determineUserContext(), and adds unit tests.

Copy link

codecov bot commented Oct 21, 2024

Codecov Report

Attention: Patch coverage is 87.80488% with 5 lines in your changes missing coverage. Please review.

Project coverage is 36.56%. Comparing base (3183eb7) to head (7e3dfe3).
Report is 140 commits behind head on master.

Files with missing lines Patch % Lines
...p/components/elements/inputs/UserContextPicker.tsx 0.00% 4 Missing ⚠️
src/app/services/userViewingContext.ts 97.29% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1195      +/-   ##
==========================================
+ Coverage   36.46%   36.56%   +0.10%     
==========================================
  Files         435      435              
  Lines       19289    19285       -4     
  Branches     5691     5686       -5     
==========================================
+ Hits         7033     7052      +19     
+ Misses      12218    12195      -23     
  Partials       38       38              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mwtrew mwtrew marked this pull request as ready for review October 21, 2024 15:06
Copy link
Contributor

@mlt47 mlt47 left a comment

Choose a reason for hiding this comment

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

This looks good.
Glad that there are tests to describe the expected behaviour more declaratively.
#1204 should also be merged for this next release to minimise the downsides of removing this query param syncing feature.

@mlt47 mlt47 merged commit 0ccb595 into master Oct 30, 2024
4 checks passed
@mlt47 mlt47 deleted the remove-user-context-url-params branch October 30, 2024 17:16
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.

2 participants