@Test public void testPlaceholderButNoArgument() { log.info("Result: {}"); assertEquals("INFO - Result: {}", log.getLogString()); }
@Test public void testArgumentWithoutPlaceholder() { log.info("Nothing", 123); assertEquals("INFO - Nothing", log.getLogString()); }
@Test public void testNullArgument() { log.info("Result: {}", (Object) null); assertEquals("INFO - Result: null", log.getLogString()); }
@Test public void testSimpleLongArgument() { log.info("Result: {}", 1234567890l); assertEquals("INFO - Result: 1234567890", log.getLogString()); }
@Test public void testSimpleBooleanArgument() { log.info("Result: {}", true); assertEquals("INFO - Result: true", log.getLogString()); }
@Test public void testSimpleStringArgument() { log.info("Hallo {}!", "Christian"); assertEquals("INFO - Hallo Christian!", log.getLogString()); }