Skip to content

Make sure to always annotate can_edit and can_view.#3126

Merged
rtibbles merged 1 commit intolearningequality:hotfixesfrom
rtibbles:can_edit_user_none
Apr 28, 2021
Merged

Make sure to always annotate can_edit and can_view.#3126
rtibbles merged 1 commit intolearningequality:hotfixesfrom
rtibbles:can_edit_user_none

Conversation

@rtibbles
Copy link
Copy Markdown
Member

Summary

Description of the change(s) you made

Fixes regression whereby can_edit and can_view were not getting annotated on the User queryset for the ChannelUser endpoint.
Adds regression test to try to catch this in the future.

Fixes #3125

@rtibbles rtibbles requested a review from bjester April 28, 2021 15:37
Copy link
Copy Markdown
Member

@bjester bjester left a comment

Choose a reason for hiding this comment

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

Looks good if tests pass

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 28, 2021

Codecov Report

Merging #3126 (ef63539) into hotfixes (28587f8) will increase coverage by 5.35%.
The diff coverage is 93.05%.

Impacted file tree graph

@@             Coverage Diff              @@
##           hotfixes    #3126      +/-   ##
============================================
+ Coverage     80.80%   86.16%   +5.35%     
============================================
  Files           281      305      +24     
  Lines         12659    16476    +3817     
============================================
+ Hits          10229    14196    +3967     
+ Misses         2430     2280     -150     
Impacted Files Coverage Δ
contentcuration/contentcuration/decorators.py 56.60% <50.00%> (-37.60%) ⬇️
...ntentcuration/contentcuration/db/models/manager.py 91.05% <90.83%> (-8.95%) ⬇️
contentcuration/contentcuration/db/models/query.py 94.23% <93.75%> (-5.77%) ⬇️
contentcuration/contentcuration/forms.py 82.35% <94.04%> (+33.89%) ⬆️
contentcuration/contentcuration/api.py 92.06% <100.00%> (+1.43%) ⬆️
contentcuration/contentcuration/apps.py 100.00% <100.00%> (+11.11%) ⬆️
contentcuration/contentcuration/celery.py 90.00% <100.00%> (-1.67%) ⬇️
...tentcuration/contentcuration/context_processors.py 100.00% <100.00%> (ø)
...ontentcuration/contentcuration/db/advisory_lock.py 100.00% <100.00%> (ø)
...tcuration/contentcuration/db/models/expressions.py 95.23% <100.00%> (-4.77%) ⬇️
... and 191 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c3f7bf8...ef63539. Read the comment docs.

@rtibbles rtibbles merged commit 315f8ae into learningequality:hotfixes Apr 28, 2021
@rtibbles rtibbles deleted the can_edit_user_none branch April 28, 2021 16:14
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