'Check authorization for staff users logged in without oauth'

def test_authorization_no_oauth_staff(self):

    staff_user = User.objects.create_user('test_staff_user', 'test_staff_user@openedx.org', 'test')
    CourseStaffRole(self.master_course_key).add_users(staff_user)
    data = {'display_name': 'CCX    Title'}
    self.client.login(username=staff_user.username, password=USER_PASSWORD)
    resp = self.client.get(self.detail_url)
    self.assertEqual(resp.status_code, status.HTTP_200_OK)
    resp = self.client.patch(self.detail_url, data, format='json')
    self.assertEqual(resp.status_code, status.HTTP_204_NO_CONTENT)
