Model repository unit tests

Finished writing unit tests for model repository