Skip to content
Snippets Groups Projects
Verified Commit 82a939d6 authored by Ernesto Rico Schmidt's avatar Ernesto Rico Schmidt
Browse files

test: add permissions for note tests

parent 26e36d59
No related branches found
No related tags found
No related merge requests found
...@@ -31,8 +31,10 @@ class UserMixin: ...@@ -31,8 +31,10 @@ class UserMixin:
self.user_common = User.objects.create_user( self.user_common = User.objects.create_user(
"herbert", "herbert@aura.radio", password="herbert" "herbert", "herbert@aura.radio", password="herbert"
) )
note_permissions = Permission.objects.filter(content_type__model="note") add_change_permissions = Permission.objects.filter(
self.user_common.user_permissions.add(*note_permissions) codename__in=["add_note", "change_note"]
)
self.user_common.user_permissions.add(*add_change_permissions)
class ShowMixin: class ShowMixin:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment