This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/master by this push: new 8a9f65b Fixed test 8a9f65b is described below commit 8a9f65b62cb294a13892f0c4100a0e0aaa1283c7 Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Fri Jan 18 07:49:25 2019 +0100 Fixed test --- .../apache/camel/component/mail/MailSplitAttachmentsTest.java | 10 +++++----- .../camel/component/mail/SpringMailSplitAttachmentsTest.java | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/components/camel-mail/src/test/java/org/apache/camel/component/mail/MailSplitAttachmentsTest.java b/components/camel-mail/src/test/java/org/apache/camel/component/mail/MailSplitAttachmentsTest.java index 6b86d1f..e7628d8 100644 --- a/components/camel-mail/src/test/java/org/apache/camel/component/mail/MailSplitAttachmentsTest.java +++ b/components/camel-mail/src/test/java/org/apache/camel/component/mail/MailSplitAttachmentsTest.java @@ -53,7 +53,7 @@ public class MailSplitAttachmentsTest extends CamelTestSupport { Message in = exchange.getIn(); in.setBody("Hello World"); in.addAttachment("logo.jpeg", new DataHandler(new FileDataSource("src/test/data/logo.jpeg"))); - in.addAttachment("license.txt", new DataHandler(new FileDataSource("src/main/resources/META-INF/LICENSE.txt"))); + in.addAttachment("log4j2.properties", new DataHandler(new FileDataSource("src/test/resources/log4j2.properties"))); } @Test @@ -77,10 +77,10 @@ public class MailSplitAttachmentsTest extends CamelTestSupport { String file2 = second.getAttachments().keySet().iterator().next(); boolean logo = file1.equals("logo.jpeg") || file2.equals("logo.jpeg"); - boolean license = file1.equals("license.txt") || file2.equals("license.txt"); + boolean license = file1.equals("log4j2.properties") || file2.equals("log4j2.properties"); assertTrue("Should have logo.jpeg file attachment", logo); - assertTrue("Should have license.txt file attachment", license); + assertTrue("Should have log4j2.properties file attachment", license); } @Test @@ -105,10 +105,10 @@ public class MailSplitAttachmentsTest extends CamelTestSupport { assertEquals(0, second.getAttachments().size()); assertEquals("logo.jpeg", first.getHeader("CamelSplitAttachmentId")); - assertEquals("license.txt", second.getHeader("CamelSplitAttachmentId")); + assertEquals("log4j2.properties", second.getHeader("CamelSplitAttachmentId")); byte[] expected1 = IOUtils.toByteArray(new FileDataSource("src/test/data/logo.jpeg").getInputStream()); - byte[] expected2 = IOUtils.toByteArray(new FileDataSource("src/main/resources/META-INF/LICENSE.txt").getInputStream()); + byte[] expected2 = IOUtils.toByteArray(new FileDataSource("src/test/resources/log4j2.properties").getInputStream()); assertArrayEquals(expected1, first.getBody(byte[].class)); assertArrayEquals(expected2, second.getBody(byte[].class)); diff --git a/components/camel-mail/src/test/java/org/apache/camel/component/mail/SpringMailSplitAttachmentsTest.java b/components/camel-mail/src/test/java/org/apache/camel/component/mail/SpringMailSplitAttachmentsTest.java index 8a055e2..7f3aaed 100644 --- a/components/camel-mail/src/test/java/org/apache/camel/component/mail/SpringMailSplitAttachmentsTest.java +++ b/components/camel-mail/src/test/java/org/apache/camel/component/mail/SpringMailSplitAttachmentsTest.java @@ -58,7 +58,7 @@ public class SpringMailSplitAttachmentsTest extends CamelSpringTestSupport { Message in = exchange.getIn(); in.setBody("Hello World"); in.addAttachment("logo.jpeg", new DataHandler(new FileDataSource("src/test/data/logo.jpeg"))); - in.addAttachment("license.txt", new DataHandler(new FileDataSource("src/main/resources/META-INF/LICENSE.txt"))); + in.addAttachment("log4j2.properties", new DataHandler(new FileDataSource("src/test/resources/log4j2.properties"))); } @Test @@ -82,10 +82,10 @@ public class SpringMailSplitAttachmentsTest extends CamelSpringTestSupport { String file2 = second.getAttachments().keySet().iterator().next(); boolean logo = file1.equals("logo.jpeg") || file2.equals("logo.jpeg"); - boolean license = file1.equals("license.txt") || file2.equals("license.txt"); + boolean license = file1.equals("log4j2.properties") || file2.equals("log4j2.properties"); assertTrue("Should have logo.jpeg file attachment", logo); - assertTrue("Should have license.txt file attachment", license); + assertTrue("Should have log4j2.properties file attachment", license); } @Test @@ -111,10 +111,10 @@ public class SpringMailSplitAttachmentsTest extends CamelSpringTestSupport { assertEquals(0, second.getAttachments().size()); assertEquals("logo.jpeg", first.getHeader("CamelSplitAttachmentId")); - assertEquals("license.txt", second.getHeader("CamelSplitAttachmentId")); + assertEquals("log4j2.properties", second.getHeader("CamelSplitAttachmentId")); byte[] expected1 = IOUtils.toByteArray(new FileDataSource("src/test/data/logo.jpeg").getInputStream()); - byte[] expected2 = IOUtils.toByteArray(new FileDataSource("src/main/resources/META-INF/LICENSE.txt").getInputStream()); + byte[] expected2 = IOUtils.toByteArray(new FileDataSource("src/test/resources/log4j2.properties").getInputStream()); assertArrayEquals(expected1, first.getBody(byte[].class)); assertArrayEquals(expected2, second.getBody(byte[].class));