unitee.client
Class RemoteTestStub
java.lang.Object
|
+--unitee.client.AbstractStreamable
|
+--unitee.client.RemoteTestStub
- Direct Known Subclasses:
- RemoteTestCaseHolderStub, RemoteTestCaseStub, RemoteTestSuiteStub
- public class RemoteTestStub
- extends AbstractStreamable
- implements Test
A stub implementation of the Test interface. This stub forwards all calls
to a remote test object (could be any subclass of that interface).
- See Also:
RemoteMethod
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
RemoteTestStub
public RemoteTestStub()
getName
public java.lang.String getName()
- Specified by:
- getName in interface Test
- Tags copied from interface: Test
- Returns:
- String
- Throws:
- Returns - the name of the test.
getQualifiedName
public java.lang.String getQualifiedName()
- Specified by:
- getQualifiedName in interface Test
- Tags copied from interface: Test
- Returns:
- String
- Throws:
- -
init
public void init()
throws ParameterException
- Specified by:
- init in interface Test
- Tags copied from interface: Test
- Returns:
- void
- Throws:
- ParameterException - Initializes the test. If the test needs parameters , the framework
is responsible to deliver them , but not through this method.
asSuite
public TestSuite asSuite()
- Description copied from interface: Test
- Tries to transform this AbstractTest into a TestSuite.
- Specified by:
- asSuite in interface Test
- Tags copied from interface: Test
- Returns:
- this AbstractTest as a TestSuite on success or
null on failure.
asTestCase
public TestCaseHolder asTestCase()
- Description copied from interface: Test
- Tries to transform this AbstractTest into a TestCaseHolder.
- Specified by:
- asTestCase in interface Test
- Tags copied from interface: Test
- Returns:
- this test as a TestSuite on success or null on failure.
setName
public void setName(java.lang.String newName)
- Specified by:
- setName in interface Test
- Tags copied from interface: Test
- Parameters:
newName
- - Returns:
- void
- Throws:
- Sets - the name of test to newTest.
getParent
public TestSuite getParent()
- Specified by:
- getParent in interface Test
- Tags copied from interface: Test
- Returns:
- TestSuite
- Throws:
- Returns - the TestSuite that holds this test.
setParent
public void setParent(TestSuite newParent)
- Specified by:
- setParent in interface Test
- Tags copied from interface: Test
- Parameters:
newParent
- - Returns:
- void
- Throws:
- -
getTestParameters
public TestParameters getTestParameters()
- Specified by:
- getTestParameters in interface Test
- Tags copied from interface: Test
- Returns:
- TestParameters
- Throws:
- Returns - the test parameters that are used by this test.
setTestParameters
public void setTestParameters(TestParameters params)
- Specified by:
- setTestParameters in interface Test
- Tags copied from interface: Test
- Parameters:
params
- - Returns:
- void
- Throws:
- -
test
public void test(TestReport report)
- Description copied from interface: Test
- Runs the test. The test can make use of the TestReport object to log interactions
with the tested software or log test results.
The method should exit normally if it executed well
-- all results are as expected and no exceptions of any kind were
generated.
test() should catch all unchecked exceptions (like AssertionException)
and notify the framework using report.testFailed()
.
Every exception wether it is a system/fatal exception ,
internal test errors (due to bad programming , etc.) , failed assertions
or exceptions thrown from the tested unit must be logged , so
the test user can be notified.
If the test developer developes pesimistic test cases (which are
recommanded) , any exception that is expected to be raised
under these conditions , may be logged , but it must not fail the Test.
- Specified by:
- test in interface Test
- Tags copied from interface: Test
- Parameters:
report
- The report to which results will be logged.