Description

We use $this->create_course() to create the non-existent course, which returns the 'id' of the new record. And then we call get_record() using that value to match the field specified in $this->enrol_localcoursefield, which is wrong. We need to match the value to the 'id' field, obviously.