Logger { public boolean isDebugEnabled() { return logger.isLoggable(FINE); } Logger(java.util.logging.Logger logger); static Logger get(Class<?> clazz); static Logger get(String name); void trace(String format, Object... args); void debug(String format, Object... args); void debug(Throwable exception, String format, Object... args); void info(String format, Object... args); void warn(Throwable exception, String format, Object... args); void warn(String format, Object... args); void error(Throwable exception, String format, Object... args); void error(Throwable exception); void error(String format, Object... args); boolean isDebugEnabled(); boolean isInfoEnabled();  }
@Test public void testIsDebugEnabled() { inner.setLevel(Level.ALL); assertTrue(logger.isDebugEnabled()); inner.setLevel(Level.FINEST); assertTrue(logger.isDebugEnabled()); inner.setLevel(Level.FINE); assertTrue(logger.isDebugEnabled()); inner.setLevel(Level.INFO); assertFalse(logger.isDebugEnabled()); inner.setLevel(Level.WARNING); assertFalse(logger.isDebugEnabled()); inner.setLevel(Level.SEVERE); assertFalse(logger.isDebugEnabled()); }