def test_deny_authenticated_show(self): g = Grant(self.obj1, self.anon_user, 'show') self.assertRaises(PermissionDenied, g.__enter__())
def test_deny_nonfriend_notify(self): g = Grant(self.obj1, self.user2, 'notify') self.assertRaises(PermissionDenied, g.__enter__())
def test_deny_nonowner_update(self): g = Grant(self.obj1, self.user1, 'update') self.assertRaises(PermissionDenied, g.__enter__())