IOC { public static void register(final IKey key, final IResolveDependencyStrategy strategy) throws RegistrationException { container.register(key, strategy); } private  IOC(); static IKey getIocKey(); static IKey getKeyForKeyStorage(); static T resolve(final IKey key, final Object ... args); static void register(final IKey key, final IResolveDependencyStrategy strategy); static void remove(final IKey key);  }
@Test public void checkRegistration() throws Exception { IKey key = mock(IKey.class); IResolveDependencyStrategy strategy = mock(IResolveDependencyStrategy.class); doNothing().when(container).register(key, strategy); IOC.register(key, strategy); verify(container, times(1)).register(key, strategy); }