I have a simple DMN decision that counts an age from the date of birth:
years and months duration(date(DOB), today()).years
It's working fine in the KIE Sandbox but I'm not able to get it running from a .scesim
file executed from maven (using mvn test
). I'm getting:
[ERROR] Errors:
[ERROR] #1: Failure reason: The decision "Age" has not been successfully evaluated: FEEL ERROR while evaluating literal expression 'years and months duration(date(DOB), today()).year... [string clipped after 50 chars, total length is 51]': Unable to find function 'date( lass org.kie.dmn.feel.runtime.functions.extended.DateFunctio )' (testAge)
[INFO]
I tried to follow https://blog.kie.org/2021/04/how-to-use-test-scenario-editor-to-test-your-dmn-asset-in-vscode.html but it didn't help.
CodePudding user response:
but I'm not able to get it running from a
.scesim
file
Likely, you haven't specified correctly one of the Input Data, so when the SceSim is run --in your case from Maven-- the evaluation fails because one of the specified input is different and wrong if compared to what you specified via the DMN JITRunner from the Sandbox.
I would expect the same behaviour if you run the same scesim for a JUnit activator and the IDE Test runner capabilities.
Best to do in this case is to provide a reproducer via the kogito-development mailing list: https://groups.google.com/g/kogito-development