1
2
3
4
5
6
7
8
9
10
11 package org.mule.providers.jms;
12
13 import org.mule.tck.providers.AbstractMessageAdapterTestCase;
14 import org.mule.umo.MessagingException;
15 import org.mule.umo.provider.UMOMessageAdapter;
16
17 public class JmsMessageAdapterTestCase extends AbstractMessageAdapterTestCase
18 {
19
20
21
22
23
24
25 public UMOMessageAdapter createAdapter(Object payload) throws MessagingException
26 {
27 return new JmsMessageAdapter(payload);
28 }
29
30
31
32
33
34
35 public Object getValidMessage() throws Exception
36 {
37 return JmsConnectorTestCase.getMessage();
38 }
39
40 public void testIllegalSpecification() throws Exception
41 {
42 JmsMessageAdapter a = (JmsMessageAdapter)this.createAdapter(this.getValidMessage());
43
44
45 a.setSpecification(JmsConstants.JMS_SPECIFICATION_102B);
46 a.setSpecification(JmsConstants.JMS_SPECIFICATION_11);
47
48 try
49 {
50
51 a.setSpecification("1.2");
52 }
53 catch (IllegalArgumentException iax)
54 {
55
56 }
57 }
58
59 }