|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.microedition.midlet.MIDlet
jmunit.framework.cldc11.Assertion
jmunit.framework.cldc11.Test
jmunit.framework.cldc11.TestCase
public abstract class TestCase
The principal class in the framework. All your test classes must extend this one. It's purpose is to encapsulate all the tests methods of the application or a specific group of them. The framework then use it to execute all.
Field Summary |
---|
Fields inherited from class jmunit.framework.cldc11.Test |
---|
name, results |
Constructor Summary | |
---|---|
TestCase(int totalOfTests,
java.lang.String name)
The default constructor. |
Method Summary | |
---|---|
protected void |
addPerformanceMeasurement(PerformanceMeasurement perfMeasurement)
Adds a PerformanceMeasurement that wants to measure the
performance of one or more tests in this TestCase. |
int |
countTestCases()
Returns the number of tests in TestCase. |
protected void |
endPerformanceMeasurements()
This method ends performance measurements. |
protected void |
removeAllPerformanceMeasurements()
Removes all PerformanceMeasurement objects that were
observing the performance of a test. |
protected void |
removePerformanceMeasurement(PerformanceMeasurement perfMeasurement)
Removes a PerformanceMeasurement that was observing the
performance of a test. |
void |
run(TestResult result)
Runs a test and collects its result in a TestResult instance. |
void |
setUp()
A empty method used by the framework to initialize the tests. |
protected void |
startPerformanceMeasurements()
This method starts the performance measurements. |
void |
tearDown()
A empty mehod used by the framework to release resources used by the tests. |
abstract void |
test(int testNumber)
This method stores all the test methods invocation. |
Methods inherited from class jmunit.framework.cldc11.Test |
---|
destroyApp, doStart, getName, pauseApp, startApp, test |
Methods inherited from class jmunit.framework.cldc11.Assertion |
---|
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotEquals, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, fail, fail, fail, fail, fail, fail, fail, fail, fail |
Methods inherited from class javax.microedition.midlet.MIDlet |
---|
getAppProperty, notifyDestroyed, notifyPaused, resumeRequest |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TestCase(int totalOfTests, java.lang.String name)
totalOfTests
- the total of test methods present in the class.name
- this testcase's name.Method Detail |
---|
public abstract void test(int testNumber) throws java.lang.Throwable
testNumber
- the test to be executed.
java.lang.Throwable
- anything that the executed test can throw.public void setUp() throws java.lang.Throwable
java.lang.Throwable
- anything that the initialization can throw.public void tearDown()
public final void run(TestResult result)
run
in class Test
result
- The TestResult collecting the results.public int countTestCases()
countTestCases
in class Test
protected final void addPerformanceMeasurement(PerformanceMeasurement perfMeasurement)
PerformanceMeasurement
that wants to measure the
performance of one or more tests in this TestCase.
perfMeasurement
- The PerformanceMeasurement object to observe the test.protected final void removePerformanceMeasurement(PerformanceMeasurement perfMeasurement)
PerformanceMeasurement
that was observing the
performance of a test.
perfMeasurement
- The PerformanceMeasurement object to remove.protected final void removeAllPerformanceMeasurements()
PerformanceMeasurement
objects that were
observing the performance of a test.
protected final void startPerformanceMeasurements()
protected final void endPerformanceMeasurements()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |