@Test
public void returnsInstanceGivenInCreationOfObjectFactory() {

    Object instance = new Object();
    ObjectModel objectModel = mock(ObjectModel.class);
    SingletonObjectFactory singletonObjectFactory = new SingletonObjectFactory<>(objectModel, instance);
    Object result = singletonObjectFactory.getInstance(null);
    assertSame(instance, result);
}