@Test
public void testCreateContainer_loggedWarnings() throws Exception {

	CreateContainerCmd ccc = Mockito.mock( CreateContainerCmd.class );
	Mockito.when( ccc.withEnv( Mockito.anyListOf( String.class ))).thenReturn( ccc );
	Mockito.when( ccc.withBinds( Mockito.anyListOf( Bind.class ))).thenReturn( ccc );
	Mockito.when( ccc.withVolumes( Mockito.anyListOf( Volume.class ))).thenReturn( ccc );
	Mockito.when( ccc.withName( Mockito.anyString())).thenReturn( ccc );
	CreateContainerResponse containerResponse = Mockito.mock( CreateContainerResponse.class );
	Mockito.when( this.dockerClient.createContainerCmd( Mockito.anyString())).thenReturn( ccc );
	Mockito.when( ccc.exec()).thenReturn( containerResponse );
	Mockito.when( containerResponse.getId()).thenReturn( "cid" );
	StartContainerCmd scc = Mockito.mock( StartContainerCmd.class );
	Mockito.when( this.dockerClient.startContainerCmd( Mockito.anyString())).thenReturn( scc );
	this.configurator.logger = Mockito.mock( Logger.class );
	Mockito.when( this.configurator.logger.isLoggable( Level.FINE )).thenReturn( true );
	Mockito.when( containerResponse.getWarnings()).thenReturn( new String[]{ "Not good.", "Stay well." });
	// Create the container (mock)
	final String imageId = "toto";
	this.configurator.createContainer( imageId );
	// Check the client
	Mockito.verify( this.dockerClient ).createContainerCmd( imageId );
	Mockito.verify( this.dockerClient ).startContainerCmd( "cid" );
	Mockito.verifyNoMoreInteractions( this.dockerClient );
	// Check the logs were correctly handled
	Mockito.verify( containerResponse, Mockito.times( 3 )).getWarnings();
	Mockito.verify( this.configurator.logger ).fine( "The following warnings have been found.\nNot good.\nStay well." );
}