Added some tests for models

Added tests for CourseQuery, Course, and Lesson classes.