|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.apache.velocity.test.EventHandlingTestCase
public class EventHandlingTestCase
Tests event handling for all event handlers except IncludeEventHandler. This is tested separately due to its complexity.
Nested Class Summary | |
---|---|
static class |
EventHandlingTestCase.TestEventCartridge
|
Field Summary |
---|
Fields inherited from interface org.apache.velocity.runtime.log.LogChute |
---|
DEBUG_ID, DEBUG_PREFIX, ERROR_ID, ERROR_PREFIX, INFO_ID, INFO_PREFIX, TRACE_ID, TRACE_PREFIX, WARN_ID, WARN_PREFIX |
Constructor Summary | |
---|---|
EventHandlingTestCase(String name)
Default constructor. |
Method Summary | |
---|---|
static void |
clearLogString()
|
static String |
getLogString()
|
void |
init(RuntimeServices rs)
Required by LogChute |
boolean |
isLevelEnabled(int level)
|
void |
log(int level,
String message)
handler for LogChute interface |
void |
log(int level,
String message,
Throwable t)
|
static void |
setLogString(String message)
|
static junit.framework.Test |
suite()
|
void |
testConfigurationEventHandlers()
Test assigning the event handlers via properties |
void |
testManualEventHandlers()
|
void |
throwException()
silly method to throw an exception to test the method invocation exception event handling |
Methods inherited from class junit.framework.TestCase |
---|
countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, tearDown, toString |
Methods inherited from class junit.framework.Assert |
---|
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public EventHandlingTestCase(String name)
Method Detail |
---|
public static junit.framework.Test suite()
public void testManualEventHandlers() throws Exception
Exception
public void testConfigurationEventHandlers() throws Exception
Exception
public void throwException() throws Exception
Exception
public void init(RuntimeServices rs)
init
in interface LogChute
public void log(int level, String message)
log
in interface LogChute
public void log(int level, String message, Throwable t)
log
in interface LogChute
public boolean isLevelEnabled(int level)
isLevelEnabled
in interface LogChute
public static void clearLogString()
public static void setLogString(String message)
public static String getLogString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |