org.exolab.jmscts.core
Class JMSTestCase

java.lang.Object
  |
  +--junit.framework.Assert
        |
        +--junit.framework.TestCase
              |
              +--org.exolab.jmscts.core.JMSTestCase
All Implemented Interfaces:
JMSTest, junit.framework.Test
Direct Known Subclasses:
AbstractConnectionFactoryTestCase

public abstract class JMSTestCase
extends junit.framework.TestCase
implements JMSTest

This class is the base class for generic test cases that can be to be run for different connection factories, connections, and sessions.

Version:
$Revision: 1.3 $ $Date: 2004/01/31 13:44:24 $
Author:
Tim Anderson
See Also:
TestContext, ProviderTestRunner, ConnectionTestRunner, SessionTestRunner, MessageTestRunner, SendReceiveTestRunner

Constructor Summary
JMSTestCase(java.lang.String name)
          Construct an instance of this class for a specific test case
 
Method Summary
 TestContext getContext()
          Return the context to test against
 java.lang.String[] getRequirements(java.lang.String test)
          Returns the requirement identifiers covered by a test case.
 void setContext(TestContext context)
          Set the context to test against
 boolean share()
          Returns if this test can share resources with other test cases.
 
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
 
Methods inherited from interface junit.framework.Test
countTestCases, run
 

Constructor Detail

JMSTestCase

public JMSTestCase(java.lang.String name)
Construct an instance of this class for a specific test case
Parameters:
name - the name of test case
Method Detail

setContext

public void setContext(TestContext context)
Set the context to test against
Specified by:
setContext in interface JMSTest
Parameters:
context - the test context

getContext

public TestContext getContext()
Return the context to test against
Specified by:
getContext in interface JMSTest
Returns:
the test context

share

public boolean share()
Returns if this test can share resources with other test cases. This implementation always returns true
Specified by:
share in interface JMSTest
Returns:
true

getRequirements

public java.lang.String[] getRequirements(java.lang.String test)
Returns the requirement identifiers covered by a test case. This implementation returns the values of any jmscts.requirement javadoc tags associated with the test case
Parameters:
test - the name of the test method
Returns:
a list of requirement identifiers covered by the test


Copyright © 2001-2004 JMS CTS Team. All Rights Reserved.