'Verifies expected behavior when course_id does not reference an existing course or is invalid.'

def test_bad_course_id(self):

    bad_org = 'badorgxxx'
    bad_team_url = self.teams_url.replace(self.course.id.org, bad_org)
    CourseEnrollmentFactory.create(user=self.user, course_id=self.course.id)
    self.client.login(username=self.user.username, password=self.test_password)
    response = self.client.get(bad_team_url)
    self.assertEqual(404, response.status_code)
    bad_team_url = bad_team_url.replace(bad_org, 'invalid/course/id')
    response = self.client.get(bad_team_url)
    self.assertEqual(404, response.status_code)
