This comment is a little confusing. I'm not totally clear on what the slug and what the course_code are supposed to contain. Please add a little clarifying comment, and some explicit test coverage too. I get a little nervous when I see uncovered regex.