|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object junit.framework.Assert junit.framework.TestCase org.springframework.test.ConditionalTestCase
public abstract class ConditionalTestCase
Superclass for tests that allows conditional test execution
at individual test method level.
The isDisabledInThisEnvironment
method is invoked before the
execution of each test method. Subclasses can override that method to return
whether or not the given test should be executed. Note that the tests will
still appear to have executed and passed; log output will show that the test
was not executed.
isDisabledInThisEnvironment(java.lang.String)
Field Summary | |
---|---|
protected Log |
logger
Logger available to subclasses |
Constructor Summary | |
---|---|
ConditionalTestCase()
Default constructor for ConditionalTestCase. |
|
ConditionalTestCase(String name)
Constructor for ConditionalTestCase with a JUnit name. |
Method Summary | |
---|---|
static int |
getDisabledTestCount()
Return the number of tests disabled in this environment. |
protected boolean |
isDisabledInThisEnvironment(String testMethodName)
Should this test run? |
protected int |
recordDisabled()
Record a disabled test. |
void |
runBare()
|
Methods inherited from class junit.framework.TestCase |
---|
countTestCases, createResult, getName, run, run, 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 |
Field Detail |
---|
protected final Log logger
Constructor Detail |
---|
public ConditionalTestCase()
public ConditionalTestCase(String name)
Method Detail |
---|
public void runBare() throws Throwable
protected boolean isDisabledInThisEnvironment(String testMethodName)
testMethodName
- name of the test method
protected int recordDisabled()
public static int getDisabledTestCount()
|
The Spring Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |