Fix RepositoryService tests

Please do not close Jira ticket, as we are working on that story to fix more breakages