Add tests for Repository