You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2014/08/28 11:04:34 UTC
git commit: CAMEL-7043: Fixed test. Thanks to Christian Ohr for the
patch.
Repository: camel
Updated Branches:
refs/heads/master 3cb2de8a2 -> 75bcfbc58
CAMEL-7043: Fixed test. Thanks to Christian Ohr for the patch.
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/75bcfbc5
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/75bcfbc5
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/75bcfbc5
Branch: refs/heads/master
Commit: 75bcfbc58eab1ffc75c799fbf134d9908c672363
Parents: 3cb2de8
Author: Claus Ibsen <da...@apache.org>
Authored: Thu Aug 28 11:04:18 2014 +0200
Committer: Claus Ibsen <da...@apache.org>
Committed: Thu Aug 28 11:04:18 2014 +0200
----------------------------------------------------------------------
.../org/apache/camel/component/hl7/MessageValidatorTest.java | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/75bcfbc5/components/camel-hl7/src/test/java/org/apache/camel/component/hl7/MessageValidatorTest.java
----------------------------------------------------------------------
diff --git a/components/camel-hl7/src/test/java/org/apache/camel/component/hl7/MessageValidatorTest.java b/components/camel-hl7/src/test/java/org/apache/camel/component/hl7/MessageValidatorTest.java
index 8219cd2..7a06682 100644
--- a/components/camel-hl7/src/test/java/org/apache/camel/component/hl7/MessageValidatorTest.java
+++ b/components/camel-hl7/src/test/java/org/apache/camel/component/hl7/MessageValidatorTest.java
@@ -46,6 +46,8 @@ public class MessageValidatorTest extends CamelTestSupport {
protected void doPreSetup() throws Exception {
defaultValidationContext = ValidationContextFactory.defaultValidation();
defaultContext = new DefaultHapiContext(defaultValidationContext);
+ // we validate separately, not during parsing or rendering
+ defaultContext.getParserConfiguration().setValidating(false);
ValidationRuleBuilder builder = new ValidationRuleBuilder() {
@Override
@@ -57,6 +59,8 @@ public class MessageValidatorTest extends CamelTestSupport {
};
customValidationContext = ValidationContextFactory.fromBuilder(builder);
customContext = new DefaultHapiContext(customValidationContext);
+ // we validate separately, not during parsing or rendering
+ customContext.getParserConfiguration().setValidating(false);
}
@Test
@@ -115,10 +119,9 @@ public class MessageValidatorTest extends CamelTestSupport {
}
@Test(expected = CamelExecutionException.class)
- @Ignore
public void testDynamicCustomHapiContext() throws Exception {
MockEndpoint mock = getMockEndpoint("mock:test6");
- mock.expectedMessageCount(1);
+ mock.expectedMessageCount(0);
Message msg = createADT01Message();
msg.setParser(customContext.getPipeParser());
template.sendBody("direct:test6", msg);