def test_remove_course_references(self): """ Unit Test: test_remove_course_references """ # Add a course dependency on the test organization api.add_organization_course(self.test_organization, self.test_course_key) self.assertEqual( len(api.get_organization_courses(self.test_organization)), 1) # Remove the course dependency with self.assertNumQueries(2): api.remove_course_references(self.test_course_key) self.assertEqual( len(api.get_organization_courses(self.test_organization)), 0)
def test_remove_course_references(self): """ Unit Test: test_remove_course_references """ # Add a course dependency on the test organization api.add_organization_course( self.test_organization, self.test_course_key ) self.assertEqual(len(api.get_organization_courses(self.test_organization)), 1) # Remove the course dependency with self.assertNumQueries(2): api.remove_course_references(self.test_course_key) self.assertEqual(len(api.get_organization_courses(self.test_organization)), 0)