Added JUnit test for RepositoryFactory class