Move to using the course_key instead of course_id

Only fixes up a few tests.