You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Willem Jiang (JIRA)" <ji...@apache.org> on 2010/03/04 11:01:45 UTC
[jira] Commented: (CAMEL-2520) NullPointerException using xpath
with MockEndpoint
[ https://issues.apache.org/activemq/browse/CAMEL-2520?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=58027#action_58027 ]
Willem Jiang commented on CAMEL-2520:
-------------------------------------
@Drapisa,
The .xpath() DSL can't work after the result.allMessages().
I just changed the code to be
{code}
XPathExpression xpath = new XPathExpression("/foo = 'bar'");
xpath.setResultType(Boolean.class);
result.allMessages().body().matches(xpath);
{code}
> NullPointerException using xpath with MockEndpoint
> --------------------------------------------------
>
> Key: CAMEL-2520
> URL: https://issues.apache.org/activemq/browse/CAMEL-2520
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 2.3.0
> Reporter: Dragisa Krsmanovic
> Assignee: Willem Jiang
> Attachments: MockXpathTest.patch
>
>
> Getting NPE when trying to do assertion like this result.allMessages().xpath("/foo", String.class).isEqualTo("bar");
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.