org.exolab.jmscts.core
Class AbstractMessageTestCase

java.lang.Object
  |
  +--junit.framework.Assert
        |
        +--junit.framework.TestCase
              |
              +--org.exolab.jmscts.core.JMSTestCase
                    |
                    +--org.exolab.jmscts.core.AbstractConnectionFactoryTestCase
                          |
                          +--org.exolab.jmscts.core.AbstractConnectionTestCase
                                |
                                +--org.exolab.jmscts.core.AbstractSessionTestCase
                                      |
                                      +--org.exolab.jmscts.core.AbstractMessageTestCase
All Implemented Interfaces:
ConnectionFactoryTestCase, ConnectionTestCase, JMSTest, MessageTestCase, SessionTestCase, junit.framework.Test
Direct Known Subclasses:
AbstractSendReceiveTestCase, BytesMessageTest, BytesMessageTest, ClearTest, IdentifierTest, JMSXGroupTest, MapMessageTest, MapMessageTest, ObjectMessageTest, ObjectMessageTest, PropertyConversionTest, PropertyTypeTest, ReadWriteTest, StreamMessageTest, StreamMessageTest

public abstract class AbstractMessageTestCase
extends AbstractSessionTestCase
implements MessageTestCase

This class provides a default implementation of the MessageTestCase interface.

Version:
$Revision: 1.8 $ $Date: 2004/01/31 13:44:24 $
Author:
Tim Anderson
See Also:
MessageTestCase, MessageTestRunner

Constructor Summary
AbstractMessageTestCase(java.lang.String name)
          Construct an instance of this class for a specific test case.
 
Method Summary
 MessagePopulator getMessagePopulator()
          Get the message populator.
 MessageTypes getMessageTypes()
          Returns the message types to test against This implementation returns the values of any jmscts.message javadoc tags associated with the test case.
 boolean shouldCreateMessage()
          Determines if messages should be pre-created and populated for the test.
 boolean startConnection()
          Returns true if the connection should be started prior to running the test.
 
Methods inherited from class org.exolab.jmscts.core.AbstractSessionTestCase
getAckTypes
 
Methods inherited from class org.exolab.jmscts.core.AbstractConnectionTestCase
setClientID
 
Methods inherited from class org.exolab.jmscts.core.AbstractConnectionFactoryTestCase
getConnectionFactoryTypes
 
Methods inherited from class org.exolab.jmscts.core.JMSTestCase
getContext, getRequirements, setContext, share
 
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 org.exolab.jmscts.core.SessionTestCase
getAckTypes
 
Methods inherited from interface org.exolab.jmscts.core.ConnectionTestCase
setClientID
 
Methods inherited from interface org.exolab.jmscts.core.ConnectionFactoryTestCase
getConnectionFactoryTypes
 
Methods inherited from interface org.exolab.jmscts.core.JMSTest
getContext, setContext, share
 
Methods inherited from interface junit.framework.Test
countTestCases, run
 

Constructor Detail

AbstractMessageTestCase

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

getMessageTypes

public MessageTypes getMessageTypes()
Returns the message types to test against This implementation returns the values of any jmscts.message javadoc tags associated with the test case. If none are specified, it defaults to MessageTypes.ALL
Specified by:
getMessageTypes in interface MessageTestCase
Returns:
the message types to test against

shouldCreateMessage

public boolean shouldCreateMessage()
Determines if messages should be pre-created and populated for the test.
Specified by:
shouldCreateMessage in interface MessageTestCase
Returns:
true

getMessagePopulator

public MessagePopulator getMessagePopulator()
Get the message populator. This may be used to populate a message with data prior to JMSTestCase.setContext(org.exolab.jmscts.core.TestContext) being invoked.
Specified by:
getMessagePopulator in interface MessageTestCase
Returns:
an instance of BasicMessagePopulator

startConnection

public boolean startConnection()
Returns true if the connection should be started prior to running the test.
Specified by:
startConnection in interface MessageTestCase
Overrides:
startConnection in class AbstractConnectionTestCase
Returns:
this implementation always returns true


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