'This test would fail if permission is checked **after** view is
actually resolved.'

def test_permission_is_checked_before_view_is_computed_perm_denied_raised(self):

    request = self.factory.get(u'/')
    request.user = self.user
    view = TestView.as_view(raise_exception=True, object=self.post)
    with self.assertRaises(PermissionDenied):
        view(request)
