'Unit Test: test_contentstore_views_entrance_exam_get_bogus_exam'

def test_contentstore_views_entrance_exam_get_bogus_exam(self):

    resp = self.client.post(self.exam_url, {'entrance_exam_minimum_score_pct': '50'}, http_accept='application/json')
    self.assertEqual(resp.status_code, 201)
    resp = self.client.get(self.exam_url)
    self.assertEqual(resp.status_code, 200)
    self.course = modulestore().get_course(self.course.id)
    updated_metadata = {'entrance_exam_id': 'i4x://org.4/course_4/chapter/ed7c4c6a4d68409998e2c8554c4629d1'}
    CourseMetadata.update_from_dict(updated_metadata, self.course, self.user)
    self.course = modulestore().get_course(self.course.id)
    resp = self.client.get(self.exam_url)
    self.assertEqual(resp.status_code, 404)
    updated_metadata = {'entrance_exam_id': '123afsdfsad90f87'}
    CourseMetadata.update_from_dict(updated_metadata, self.course, self.user)
    self.course = modulestore().get_course(self.course.id)
    resp = self.client.get(self.exam_url)
    self.assertEqual(resp.status_code, 404)
