Is there any way to inject a mock implementation of a SharedServiceRegistry for testing purposes? I am trying to test a class method that accesses the SharedServiceRegistry while running unit tests on a VDE.
I was able to mock out the storage service by the following, where MockStorageImpl is a mock class that implements the Storage interface:
Storage storage = new MockStorageImpl(); ServiceFactory.getServiceRegistry().register(Storage.class, storage);
But I can not find a way to provide a mock implementation of the SharedServiceRegistry.
It looks like it should be possible to define in a .properties file the name of the class that should implement this interface so that the DependencyInjectionServiceLoader can create it when it calls getImplementationName();