[jboss-jira] [JBoss JIRA] (DROOLS-2388) DMN Namespace unmarshalling differs from standard one when calling DMNValidator.validate method with File param
Tibor Zimányi (JIRA)
issues at jboss.org
Tue Mar 20 12:09:02 EDT 2018
[ https://issues.jboss.org/browse/DROOLS-2388?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13548644#comment-13548644 ]
Tibor Zimányi commented on DROOLS-2388:
---------------------------------------
Steps to reproduce:
1. Checkout branch from this PR [1]
2. Change getLocalPart() on this line to toString() [2]
3. Run test [3]
4. Run test [4]
Test from point 3. fails on validation error, because the validation rule fired - the typeRef from the provided Definitions contains namespace. However test from point 4. pass, because unmarshalling from the validate method that takes Reader as an input works differently and doesn't fill namespace in the typeref. This is inconsistent, because a user could expect that the validate methods behave the same when the same file is used (either for getting Definitions or providing it directly to the validate method).
[1] https://github.com/kiegroup/drools/pull/1810
[2] https://github.com/baldimir/drools/blob/5a9cb6f09a52cdc46b7cafb52cf615f889f9f7f5/kie-dmn/kie-dmn-validation/src/main/resources/dmn-validation-rules-typeref.drl#L100
[3] https://github.com/baldimir/drools/blob/7a2c6374351d57011ae67d4fc28900ea821f0220/kie-dmn/kie-dmn-validation/src/test/java/org/kie/dmn/validation/ValidatorTest.java#L59
[4] https://github.com/baldimir/drools/blob/7a2c6374351d57011ae67d4fc28900ea821f0220/kie-dmn/kie-dmn-validation/src/test/java/org/kie/dmn/validation/ValidatorTest.java#L73
> DMN Namespace unmarshalling differs from standard one when calling DMNValidator.validate method with File param
> ---------------------------------------------------------------------------------------------------------------
>
> Key: DROOLS-2388
> URL: https://issues.jboss.org/browse/DROOLS-2388
> Project: Drools
> Issue Type: Bug
> Components: dmn engine
> Affects Versions: 7.6.0.Final
> Reporter: Tibor Zimányi
> Assignee: Fedor Gavrilov
> Priority: Minor
>
> When using DMNValidator.validate method that takes a DMN file as a parameter, the validation results are sometimes different from results of validate method that takes Definitions as an input parameter. The main difference looks to be namespace parsing.
> Reproducer can be found here: https://github.com/kiegroup/drools/pull/1814
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
More information about the jboss-jira
mailing list