Code example for LogRecord

Methods: setLevel

0
	/* 
	 * Test log(LogRecord) for a normal log record. Meanwhile the logger has an 
	 * inappropriate level, no filter, no parent. 
	 */ 
	public void testLog_LogRecord_InppropriateLevelNoFilterNoParent() { 
		LogRecord r = new LogRecord(Level.INFO,
				"testLog_LogRecord_InppropriateLevelNoFilterNoParent"); 
 
		this.sharedLogger.setLevel(Level.WARNING);
		this.sharedLogger.log(r);
		assertTrue(CallVerificationStack.getInstance().empty());
 
		r.setLevel(Level.OFF);
		this.sharedLogger.setLevel(Level.OFF);
		this.sharedLogger.log(r);
		assertTrue(CallVerificationStack.getInstance().empty());
	} 
 
	/* 
	 * Test log(LogRecord) for a normal log record. Meanwhile the logger has an 
	 * appropriate level, a filter that accepts the fed log record, no parent.