Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(3)  |  Call(2)  |  Derive(0)  |  Import(1)

src/d/j/django-generic-permissions-0.1.0/django_generic_permissions/tests.py   django-generic-permissions(Download)
 
from .backends import add_permission
from .backends import get_permissions
from .backends import has_permission
from .backends import Permission
        add_permission(self.perm_3, temp_user)
 
        added_permissions = get_permissions(temp_user)
 
        # Verify all permissions were added correctly and there are no extras
        remove_permission(self.perm_2, temp_user)
 
        current_permissions = get_permissions(temp_user)
 
        # Verify the removed permission is not in the current list