'Test that a user enrolls and gets "Student" forum role for that course which he creates and remains
enrolled even the course is deleted and keeps its "Student" forum role for that course'

def test_user_forum_default_role_on_course_deletion(self):

    self.assertTrue(CourseEnrollment.is_enrolled(self.user, self.course_key))
    self.assertTrue(self.user.roles.filter(name='Student', course_id=self.course_key))
    delete_course(self.course_key, self.user.id)
    self.assertTrue(CourseEnrollment.is_enrolled(self.user, self.course_key))
    self.assertTrue(self.user.roles.filter(name='Student', course_id=self.course_key))
