|
||||||||||
PREV CLASS (src) NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectTestCase
org.objectweb.jtests.jms.framework.JMSTestCase (src)
org.objectweb.jtests.jms.framework.PTPTestCase (src)
org.objectweb.jtests.jms.conform.message.properties.MessagePropertyTest
Test the javax.jms.Message
properties.
See JMS Specification, §3.5 Message Properties (p.32-37)
Field Summary |
Fields inherited from class org.objectweb.jtests.jms.framework.PTPTestCase (src) |
admin, ctx, receiver, receiverConnection, receiverQCF, receiverQueue, receiverSession, sender, senderConnection, senderQCF, senderQueue, senderSession |
Constructor Summary | |
MessagePropertyTest(java.lang.String name)
|
Method Summary | |
static Test |
suite()
Method to use this class in a Test suite |
void |
testClearProperties_1()
Test that the Message.clearProperties() method deletes all the
properties of the Message. |
void |
testClearProperties_2()
Test that the Message.clearProperties() method does not clear the
value of the Message's body. |
void |
testGetBooleanProperty()
Test that an attempt to get a boolean property which does not exist
returns false |
void |
testGetByteProperty()
Test that an attempt to get a byte property which does not exist throw
a java.lang.NumberFormatException |
void |
testGetDoubleProperty()
Test that an attempt to get a double property which does not exist throw
a java.lang.NullPointerException |
void |
testGetFloatProperty()
Test that an attempt to get a float property which does not exist throw
a java.lang.NullPointerException |
void |
testGetIntProperty()
Test that an attempt to get a int property which does not exist throw
a java.lang.NumberFormatException |
void |
testGetLongProperty()
Test that an attempt to get a long property which does not exist throw
a java.lang.NumberFormatException |
void |
testGetObjectProperty()
Test that a null value is returned by the Message.getObjectProperty() method
if a property by the specified name does not exits. |
void |
testGetPropertyNames()
Test that the Message.getPropertyNames() method does not return
the name of the JMS standard header fields (e.g. |
void |
testGetShortProperty()
Test that an attempt to get a short property which does not exist throw
a java.lang.NumberFormatException |
void |
testGetStringProperty()
Test that a null value is returned by the Message.getStringProperty() method
if a property by the specified name does not exits. |
void |
testPropertyIteration()
Test that the Message.getPropertyNames() method returns an empty
java.util.Enumeration if there is no properties. |
void |
testSetObjectProperty_1()
if a property is set as a Float with the Message.setObjectProperty()
method, it can be retrieve directly as a double by Message.getFloatProperty() |
void |
testSetObjectProperty_2()
Test that any other class than Boolean, Byte, Short, Integer, Long,
Float, Double and String used in the Message.setObjectProperty()
method throws a javax.jms.MessageFormatException . |
Methods inherited from class org.objectweb.jtests.jms.framework.PTPTestCase (src) |
setUp, tearDown |
Methods inherited from class org.objectweb.jtests.jms.framework.JMSTestCase (src) |
fail |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MessagePropertyTest(java.lang.String name)
Method Detail |
public void testSetObjectProperty_2()
Boolean, Byte, Short, Integer, Long,
Float, Double
and String
used in the Message.setObjectProperty()
method throws a javax.jms.MessageFormatException
.
public void testSetObjectProperty_1()
Float
with the Message.setObjectProperty()
method, it can be retrieve directly as a double
by Message.getFloatProperty()
public void testGetObjectProperty()
null
value is returned by the Message.getObjectProperty()
method
if a property by the specified name does not exits.
public void testGetStringProperty()
null
value is returned by the Message.getStringProperty()
method
if a property by the specified name does not exits.
public void testGetDoubleProperty()
double
property which does not exist throw
a java.lang.NullPointerException
public void testGetFloatProperty()
float
property which does not exist throw
a java.lang.NullPointerException
public void testGetLongProperty()
long
property which does not exist throw
a java.lang.NumberFormatException
public void testGetIntProperty()
int
property which does not exist throw
a java.lang.NumberFormatException
public void testGetShortProperty()
short
property which does not exist throw
a java.lang.NumberFormatException
public void testGetByteProperty()
byte
property which does not exist throw
a java.lang.NumberFormatException
public void testGetBooleanProperty()
boolean
property which does not exist
returns false
public void testGetPropertyNames()
Message.getPropertyNames()
method does not return
the name of the JMS standard header fields (e.g. JMSCorrelationID
.
public void testPropertyIteration()
Message.getPropertyNames()
method returns an empty
java.util.Enumeration
if there is no properties.
public void testClearProperties_2()
Message.clearProperties()
method does not clear the
value of the Message's body.
public void testClearProperties_1()
Message.clearProperties()
method deletes all the
properties of the Message.
public static Test suite()
|
||||||||||
PREV CLASS (src) NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |