Slf4jLogger implements Logger { @Override public void info( String message, Object... params ) { if ( delegate.isInfoEnabled() ) { delegate.info( formatMessage( message, params ) ); } } Slf4jLogger( org.slf4j.Logger delegate ); @Override void error( String message, Throwable cause ); @Override void info( String message, Object... params ); @Override void warn( String message, Object... params ); @Override void warn( String message, Throwable cause ); @Override void debug( String message, Object... params ); @Override void trace( String message, Object... params ); @Override boolean isTraceEnabled(); @Override boolean isDebugEnabled();  }
@Test void shouldLogInfoWithMessageAndParams() { when( logger.isInfoEnabled() ).thenReturn( true ); String message = "One %s, two %s, three %s"; Object[] params = {"111", "222", "333"}; slf4jLogger.info( message, params ); verify( logger ).info( "One 111, two 222, three 333" ); }