Methods Summary |
---|
public void | testAllInt()Tests Priority.ALL_INT.
assertEquals(Integer.MIN_VALUE, Priority.ALL_INT);
|
public void | testDEBUG()Tests Priority.DEBUG.
assertTrue(Priority.DEBUG instanceof Level);
|
public void | testDebugInt()Tests Priority.DEBUG_INT.
assertEquals(10000, Priority.DEBUG_INT);
|
public void | testDotlessLowerI()Test that dotless lower I + "nfo" is recognized as INFO.
Priority level = Priority.toPriority("\u0131nfo");
assertEquals("INFO", level.toString());
|
public void | testDottedLowerI()Test that dotted lower I + "nfo" is recognized as INFO
even in Turkish locale.
Locale defaultLocale = Locale.getDefault();
Locale turkey = new Locale("tr", "TR");
Locale.setDefault(turkey);
Priority level = Priority.toPriority("info");
Locale.setDefault(defaultLocale);
assertEquals("INFO", level.toString());
|
public void | testERROR()Tests Priority.ERROR.
assertTrue(Priority.ERROR instanceof Level);
|
public void | testEqualsLevel()Tests Priority.equals(Level.DEBUG).
//
// this behavior violates the equals contract.
//
assertTrue(Priority.DEBUG.equals(Level.DEBUG));
|
public void | testEqualsNull()Tests Priority.equals(null).
assertFalse(Priority.DEBUG.equals(null));
|
public void | testErrorInt()Tests Priority.ERROR_INT.
assertEquals(40000, Priority.ERROR_INT);
|
public void | testFatal()Tests Priority.FATAL.
assertTrue(Priority.FATAL instanceof Level);
|
public void | testFatalInt()Tests Priority.FATAL_INT.
assertEquals(50000, Priority.FATAL_INT);
|
public void | testGetAllPossiblePriorities()Tests getAllPossiblePriorities().
Priority[] priorities = Priority.getAllPossiblePriorities();
assertEquals(5, priorities.length);
|
public void | testINFO()Tests Priority.INFO.
assertTrue(Priority.INFO instanceof Level);
|
public void | testInfoInt()Tests Priority.INFO_INT.
assertEquals(20000, Priority.INFO_INT);
|
public void | testOffInt()Tests Priority.OFF_INT.
assertEquals(Integer.MAX_VALUE, Priority.OFF_INT);
|
public void | testToPriorityInt()Tests toPriority(int).
assertTrue(Priority.toPriority(Priority.DEBUG_INT) == Level.DEBUG);
|
public void | testToPriorityIntPriority()Tests toPriority(int, Priority).
assertTrue(Priority.toPriority(17, Priority.DEBUG) == Priority.DEBUG);
|
public void | testToPriorityString()Tests toPriority(String).
assertTrue(Priority.toPriority("DEBUG") == Level.DEBUG);
|
public void | testToPriorityStringPriority()Tests toPriority(String, Priority).
assertTrue(Priority.toPriority("foo", Priority.DEBUG) == Priority.DEBUG);
|
public void | testWARN()Tests Priority.WARN.
assertTrue(Priority.WARN instanceof Level);
|
public void | testWarnInt()Tests Priority.WARN_INT.
assertEquals(30000, Priority.WARN_INT);
|