Skip to content
Browse files

Merge pull request #51 from garyrussell/INTSAMPLES-75

* garyrussell-INTSAMPLES-75:
  INTSAMPLES-75 Fix For 2.2.0.M1
  • Loading branch information...
2 parents 7e70f81 + 566e1a7 commit bddb52b46966d7f06f01d0b8a7bd45983f974400 Gunnar Hillert committed May 16, 2012
View
2 advanced/dynamic-ftp/pom.xml
@@ -8,7 +8,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<spring.framework.version>3.1.0.RELEASE</spring.framework.version>
- <spring.integration.version>2.1.0.RELEASE</spring.integration.version>
+ <spring.integration.version>2.2.0.M1</spring.integration.version>
<log4j.version>1.2.16</log4j.version>
<junit.version>4.10</junit.version>
</properties>
View
11 ...est/java/org/springframework/integration/samples/ftp/FtpOutboundChannelAdapterSample.java
@@ -27,6 +27,7 @@
import org.springframework.integration.Message;
import org.springframework.integration.MessageChannel;
import org.springframework.integration.MessageHandlingException;
+import org.springframework.integration.MessagingException;
import org.springframework.integration.support.MessageBuilder;
/**
@@ -47,14 +48,14 @@ public void runDemo() throws Exception{
.build();
try {
channel.send(message);
- } catch (MessageHandlingException e) {
+ } catch (MessagingException e) {
assertTrue(e.getCause().getCause() instanceof UnknownHostException);
assertEquals("host.for.cust1", e.getCause().getCause().getMessage());
}
// send another so we can see in the log we don't create the ac again.
try {
channel.send(message);
- } catch (MessageHandlingException e) {
+ } catch (MessagingException e) {
assertTrue(e.getCause().getCause() instanceof UnknownHostException);
assertEquals("host.for.cust1", e.getCause().getCause().getMessage());
}
@@ -63,7 +64,7 @@ public void runDemo() throws Exception{
.setHeader("customer", "cust2").build();
try {
channel.send(message);
- } catch (MessageHandlingException e) {
+ } catch (MessagingException e) {
assertTrue(e.getCause().getCause() instanceof UnknownHostException);
assertEquals("host.for.cust2", e.getCause().getCause().getMessage());
}
@@ -74,7 +75,7 @@ public void runDemo() throws Exception{
.setHeader("customer", "cust3").build();
try {
channel.send(message);
- } catch (MessageHandlingException e) {
+ } catch (MessagingException e) {
assertTrue(e.getCause().getCause() instanceof UnknownHostException);
assertEquals("host.for.cust3", e.getCause().getCause().getMessage());
}
@@ -85,7 +86,7 @@ public void runDemo() throws Exception{
.setHeader("customer", "cust1").build();
try {
channel.send(message);
- } catch (MessageHandlingException e) {
+ } catch (MessagingException e) {
assertTrue(e.getCause().getCause() instanceof UnknownHostException);
assertEquals("host.for.cust1", e.getCause().getCause().getMessage());
}

0 comments on commit bddb52b

Please sign in to comment.
Something went wrong with that request. Please try again.