def test_workflow_template_transition_field_list_view_with_access(self):
    self._create_test_workflow_template_transition_field()
    self.grant_access(obj=self.test_workflow_template, permission=permission_workflow_template_edit)
    self._clear_events()
    response = self._request_test_workflow_template_transition_field_list_view()
    self.assertContains(response=response, text=self.test_workflow_template_transition_field.label, status_code=200)
    events = self._get_test_events()
    self.assertEqual(events.count(), 0)
def test_workflow_template_transition_field_list_view_with_access(self):
    self._create_test_workflow_template_transition_field()
    self.grant_access(obj=self.test_workflow_template, permission=permission_workflow_template_edit)
    self._clear_events()
    response = self._request_test_workflow_template_transition_field_list_view()
    self.assertContains(response=response, text=self.test_workflow_template_transition_field.label, status_code=200)
    events = self._get_test_events()
    self.assertEqual(events.count(), 0)