TET
Class SimpleTestCase

java.lang.Object
  extended byTET.TestCase
      extended byTET.SimpleTestCase

public abstract class SimpleTestCase
extends TestCase

SimpleTestCase is a base class for TETware test cases.

To create a new test case, derive a new class from SimpleTestCase. Test purposes are defined as public instance methods of the form:

 public void i#t#(TestSession ts)
 
Where each '#' represents a sequence of one or more digits. The first sequence of digits (the "i"-string) denotes the number of the invocable component to which the test purpose belongs. The second sequence (the "t"-string) is used to determine the execution order of the test purposes, AKA the test purpose number. Note that the sequence of digits is not used as the test purpose number, but as a comparison to other methods in the same IC.

A test purpose method may throw exceptions, but these will result in an unresolved result code being marked for that test.

The startup() and cleanup() methods can be overridden to provide code which is executed before and after all test purpose methods.

Attempts to load this class in the same virtual machine as ChildTestCase will fail. It is only permissible to have one type of test case in one virtual machine.


Constructor Summary
SimpleTestCase()
          Constructs a new SimpleTestCase.
 
Method Summary
 void cleanup(TestSession ts)
          Method to be executed at test case shutdown.
static void main(java.lang.String[] args, SimpleTestCase tc)
          Begin execution of a test case using the default test session.
static void main(java.lang.String pname, java.lang.String[] args, SimpleTestCase tc)
          Begin execution of a test case using the default test session.
static void main(java.lang.String pname, java.lang.String[] args, SimpleTestCase tc, TestSession ts)
          Deprecated. Not part of the published API.
 void startup(TestSession ts)
          Method to be executed at test case startup.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleTestCase

public SimpleTestCase()
Constructs a new SimpleTestCase.

Method Detail

main

public static void main(java.lang.String[] args,
                        SimpleTestCase tc)
Begin execution of a test case using the default test session. The name of the test case is taken from the class of the tc argument.

Parameters:
args - the command line arguments.
tc - the testcase.

main

public static void main(java.lang.String pname,
                        java.lang.String[] args,
                        SimpleTestCase tc)
Begin execution of a test case using the default test session.

Parameters:
pname - the name of the test case.
args - the command line arguments.
tc - the testcase.

main

public static void main(java.lang.String pname,
                        java.lang.String[] args,
                        SimpleTestCase tc,
                        TestSession ts)
Deprecated. Not part of the published API.

Begin execution of a test case.

Parameters:
pname - the name of the test case.
args - the command line arguments.
tc - the test case.
ts - the test session to use.

startup

public void startup(TestSession ts)
Method to be executed at test case startup. It can be overridden by the instance of this class implementing the test.

Parameters:
ts - the TestSession object for the current test run.

cleanup

public void cleanup(TestSession ts)
Method to be executed at test case shutdown. It can be overridden by the instance of this class implementing the test.

Parameters:
ts - the TestSession object for the current test run.