### Question:
InternalLoggerFactory { public static InternalLogger getInstance(Class<?> clazz) { return getInstance(clazz.getName()); }  static InternalLoggerFactory getDefaultFactory(); static void setDefaultFactory(InternalLoggerFactory defaultFactory); static InternalLogger getInstance(Class<?> clazz); static InternalLogger getInstance(String name); abstract InternalLogger newInstance(String name);  }### Answer:
@Test public void shouldReturnWrappedLogger() { assertNotSame(mock, InternalLoggerFactory.getInstance("mock")); }
@Test public void testIsDebugEnabled() { expect(mock.isDebugEnabled()).andReturn(true); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); assertTrue(logger.isDebugEnabled()); verify(mock); }
@Test public void testIsInfoEnabled() { expect(mock.isInfoEnabled()).andReturn(true); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); assertTrue(logger.isInfoEnabled()); verify(mock); }
@Test public void testIsWarnEnabled() { expect(mock.isWarnEnabled()).andReturn(true); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); assertTrue(logger.isWarnEnabled()); verify(mock); }
@Test public void testIsErrorEnabled() { expect(mock.isErrorEnabled()).andReturn(true); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); assertTrue(logger.isErrorEnabled()); verify(mock); }
@Test public void testDebug() { mock.debug("a"); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.debug("a"); verify(mock); }
@Test public void testDebugWithException() { mock.debug("a", e); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.debug("a", e); verify(mock); }
@Test public void testInfo() { mock.info("a"); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.info("a"); verify(mock); }
@Test public void testInfoWithException() { mock.info("a", e); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.info("a", e); verify(mock); }
@Test public void testWarn() { mock.warn("a"); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.warn("a"); verify(mock); }
@Test public void testWarnWithException() { mock.warn("a", e); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.warn("a", e); verify(mock); }
@Test public void testError() { mock.error("a"); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.error("a"); verify(mock); }
@Test public void testErrorWithException() { mock.error("a", e); replay(mock); InternalLogger logger = InternalLoggerFactory.getInstance("mock"); logger.error("a", e); verify(mock); }