This is an automated email from the ASF dual-hosted git repository.
mweiler pushed a commit to branch main
in repository
https://gitbox.apache.org/repos/asf/incubator-kie-kogito-runtimes.git
The following commit(s) were added to refs/heads/main by this push:
new 50bebc8eea [incubator-kie-issues#2046] Fix for lambda-expressions
parsing error. (#4009)
50bebc8eea is described below
commit 50bebc8eeaf2b6e6906aae0b730fa10a5fcf3d0d
Author: Alisha Mohamed Ali <[email protected]>
AuthorDate: Fri Aug 15 20:20:48 2025 +0530
[incubator-kie-issues#2046] Fix for lambda-expressions parsing error.
(#4009)
* DBACLD-186820: Fix for lambda-expressions parsing error.
* added unit test case
* added unit test case
* formating code
* formating code
---------
Co-authored-by: Alisha Mohamed Ali <[email protected]>
---
.../java/org/jbpm/bpmn2/objects/MyStaticClass.java | 28 ++++
.../src/main/java/org/jbpm/bpmn2/objects/User.java | 66 +++++++++
.../bpmn2/flow/BPMN2-LambdaExpressionParser.bpmn2 | 154 +++++++++++++++++++++
.../org/jbpm/bpmn2/ScriptLambdaValidationTest.java | 45 ++++++
.../process/JavaRuleFlowProcessValidator.java | 3 +
.../process/JavaRuleFlowProcessValidatorTest.java | 50 +++++++
6 files changed, 346 insertions(+)
diff --git
a/jbpm/jbpm-tests/src/main/java/org/jbpm/bpmn2/objects/MyStaticClass.java
b/jbpm/jbpm-tests/src/main/java/org/jbpm/bpmn2/objects/MyStaticClass.java
new file mode 100644
index 0000000000..44c10e340f
--- /dev/null
+++ b/jbpm/jbpm-tests/src/main/java/org/jbpm/bpmn2/objects/MyStaticClass.java
@@ -0,0 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.jbpm.bpmn2.objects;
+
+public class MyStaticClass {
+
+ public static void log(String message) {
+
+ System.out.println("MyStaticClass :: " + message);
+ }
+
+}
diff --git a/jbpm/jbpm-tests/src/main/java/org/jbpm/bpmn2/objects/User.java
b/jbpm/jbpm-tests/src/main/java/org/jbpm/bpmn2/objects/User.java
new file mode 100644
index 0000000000..cb5625a0ce
--- /dev/null
+++ b/jbpm/jbpm-tests/src/main/java/org/jbpm/bpmn2/objects/User.java
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.jbpm.bpmn2.objects;
+
+import java.time.LocalDate;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+
+public class User {
+ private String name;
+
+ @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd")
+ private LocalDate dob;
+
+ private Boolean isValid;
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public LocalDate getDob() {
+ return dob;
+ }
+
+ public void setDob(LocalDate dob) {
+ this.dob = dob;
+ }
+
+ public Boolean getIsValid() {
+ return isValid;
+ }
+
+ public Boolean isIsValid() {
+ return isValid;
+ }
+
+ public void setIsValid(Boolean isValid) {
+ this.isValid = isValid;
+ }
+
+ @Override
+ public String toString() {
+ return "User [name=" + name + ", dob=" + dob + ", isValid=" + isValid
+ "]";
+ }
+
+}
diff --git
a/jbpm/jbpm-tests/src/test/bpmn/org/jbpm/bpmn2/flow/BPMN2-LambdaExpressionParser.bpmn2
b/jbpm/jbpm-tests/src/test/bpmn/org/jbpm/bpmn2/flow/BPMN2-LambdaExpressionParser.bpmn2
new file mode 100644
index 0000000000..be8cbaeaa5
--- /dev/null
+++
b/jbpm/jbpm-tests/src/test/bpmn/org/jbpm/bpmn2/flow/BPMN2-LambdaExpressionParser.bpmn2
@@ -0,0 +1,154 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ -->
+<bpmn2:definitions xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL"
xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
xmlns:bpsim="http://www.bpsim.org/schemas/1.0"
xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
xmlns:drools="http://www.jboss.org/drools" xmlns:xsi="xsi"
id="_XZ5wMFmeED6ZMPmYwBas4A"
xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd
http://www.jboss.org/drools drools.xsd http://www [...]
+ <bpmn2:itemDefinition id="_validPersonItem"
structureRef="org.jbpm.bpmn2.objects.User"/>
+ <bpmn2:collaboration id="_AF80B16B-0312-4C9C-A9EF-02418C457128"
name="Default Collaboration">
+ <bpmn2:participant id="_DEEB0CB4-CF68-4BF0-9608-89CD60CA282A" name="Pool
Participant" processRef="BPMN2_LambdaExpressionParser"/>
+ </bpmn2:collaboration>
+ <bpmn2:process id="BPMN2_LambdaExpressionParser"
drools:packageName="org.jbpm.bpmn2.flow" drools:version="1.0"
drools:adHoc="false" name="BPMN2-LambdaExpressionParser" isExecutable="true"
processType="Public">
+ <bpmn2:property id="validPerson" itemSubjectRef="_validPersonItem"
name="validPerson"/>
+ <bpmn2:sequenceFlow id="_4E987416-C63C-47D2-8DAB-1F35DC2DC8EB"
sourceRef="_353B670A-55FB-4B3B-A602-B0748D6C50D3"
targetRef="_A216A460-4D76-4087-8A52-E1301F820DF9"/>
+ <bpmn2:sequenceFlow id="_E6EDF2A5-40D5-4C91-AA0E-B53477100C35"
sourceRef="_9E3688A2-CC8C-4A98-A925-0EAA0D1C3174"
targetRef="_353B670A-55FB-4B3B-A602-B0748D6C50D3"/>
+ <bpmn2:sequenceFlow id="_29E5D913-A55E-4234-B417-8716D2D71392"
sourceRef="_B326C635-BC57-4CDD-B28E-96579F74F4BB"
targetRef="_9E3688A2-CC8C-4A98-A925-0EAA0D1C3174"/>
+ <bpmn2:endEvent id="_A216A460-4D76-4087-8A52-E1301F820DF9">
+ <bpmn2:incoming>_4E987416-C63C-47D2-8DAB-1F35DC2DC8EB</bpmn2:incoming>
+ </bpmn2:endEvent>
+ <bpmn2:scriptTask id="_353B670A-55FB-4B3B-A602-B0748D6C50D3" name="Lambda
Expression" scriptFormat="http://www.java.com/java">
+ <bpmn2:extensionElements>
+ <drools:metaData name="elementname">
+ <drools:metaValue><![CDATA[Lambda Expression]]></drools:metaValue>
+ </drools:metaData>
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>_E6EDF2A5-40D5-4C91-AA0E-B53477100C35</bpmn2:incoming>
+ <bpmn2:outgoing>_4E987416-C63C-47D2-8DAB-1F35DC2DC8EB</bpmn2:outgoing>
+ <bpmn2:script>java.util.List<org.jbpm.bpmn2.objects.User>
personsList = new java.util.ArrayList<org.jbpm.bpmn2.objects.User>();
+org.jbpm.bpmn2.objects.User testUser = new org.jbpm.bpmn2.objects.User();
+testUser.setName("TestUser");
+testUser.setIsValid(true);
+personsList.add(testUser);
+
+org.jbpm.bpmn2.objects.User foundPerson = personsList.stream()
+.filter(p -> p.getIsValid())
+.findFirst()
+.orElse(null);
+kcontext.setVariable("validPerson", foundPerson);
+System.out.println("FOUND VALID PERSON " + validPerson);</bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:scriptTask id="_9E3688A2-CC8C-4A98-A925-0EAA0D1C3174" name="Static
Script" scriptFormat="http://www.java.com/java">
+ <bpmn2:extensionElements>
+ <drools:metaData name="elementname">
+ <drools:metaValue><![CDATA[Static Script]]></drools:metaValue>
+ </drools:metaData>
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>_29E5D913-A55E-4234-B417-8716D2D71392</bpmn2:incoming>
+ <bpmn2:outgoing>_E6EDF2A5-40D5-4C91-AA0E-B53477100C35</bpmn2:outgoing>
+
<bpmn2:script>org.jbpm.bpmn2.objects.MyStaticClass.log("heeeeere");</bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:startEvent id="_B326C635-BC57-4CDD-B28E-96579F74F4BB">
+ <bpmn2:outgoing>_29E5D913-A55E-4234-B417-8716D2D71392</bpmn2:outgoing>
+ </bpmn2:startEvent>
+ </bpmn2:process>
+ <bpmndi:BPMNDiagram>
+ <bpmndi:BPMNPlane bpmnElement="BPMN2_LambdaExpressionParser">
+ <bpmndi:BPMNShape id="shape__B326C635-BC57-4CDD-B28E-96579F74F4BB"
bpmnElement="_B326C635-BC57-4CDD-B28E-96579F74F4BB">
+ <dc:Bounds height="56" width="56" x="287" y="215"/>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="shape__9E3688A2-CC8C-4A98-A925-0EAA0D1C3174"
bpmnElement="_9E3688A2-CC8C-4A98-A925-0EAA0D1C3174">
+ <dc:Bounds height="102" width="154" x="423" y="192"/>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="shape__353B670A-55FB-4B3B-A602-B0748D6C50D3"
bpmnElement="_353B670A-55FB-4B3B-A602-B0748D6C50D3">
+ <dc:Bounds height="102" width="154" x="657" y="192"/>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="shape__A216A460-4D76-4087-8A52-E1301F820DF9"
bpmnElement="_A216A460-4D76-4087-8A52-E1301F820DF9">
+ <dc:Bounds height="56" width="56" x="891" y="215"/>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge
id="edge_shape__B326C635-BC57-4CDD-B28E-96579F74F4BB_to_shape__9E3688A2-CC8C-4A98-A925-0EAA0D1C3174"
bpmnElement="_29E5D913-A55E-4234-B417-8716D2D71392">
+ <di:waypoint x="315" y="243"/>
+ <di:waypoint x="500" y="243"/>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge
id="edge_shape__9E3688A2-CC8C-4A98-A925-0EAA0D1C3174_to_shape__353B670A-55FB-4B3B-A602-B0748D6C50D3"
bpmnElement="_E6EDF2A5-40D5-4C91-AA0E-B53477100C35">
+ <di:waypoint x="500" y="243"/>
+ <di:waypoint x="734" y="243"/>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge
id="edge_shape__353B670A-55FB-4B3B-A602-B0748D6C50D3_to_shape__A216A460-4D76-4087-8A52-E1301F820DF9"
bpmnElement="_4E987416-C63C-47D2-8DAB-1F35DC2DC8EB">
+ <di:waypoint x="734" y="243"/>
+ <di:waypoint x="919" y="243"/>
+ </bpmndi:BPMNEdge>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+ <bpmn2:relationship type="BPSimData">
+ <bpmn2:extensionElements>
+ <bpsim:BPSimData>
+ <bpsim:Scenario id="default" name="Simulationscenario">
+ <bpsim:ScenarioParameters/>
+ <bpsim:ElementParameters
elementRef="_B326C635-BC57-4CDD-B28E-96579F74F4BB">
+ <bpsim:TimeParameters>
+ <bpsim:ProcessingTime>
+ <bpsim:NormalDistribution mean="0" standardDeviation="0"/>
+ </bpsim:ProcessingTime>
+ </bpsim:TimeParameters>
+ </bpsim:ElementParameters>
+ <bpsim:ElementParameters
elementRef="_9E3688A2-CC8C-4A98-A925-0EAA0D1C3174">
+ <bpsim:TimeParameters>
+ <bpsim:ProcessingTime>
+ <bpsim:NormalDistribution mean="0" standardDeviation="0"/>
+ </bpsim:ProcessingTime>
+ </bpsim:TimeParameters>
+ <bpsim:ResourceParameters>
+ <bpsim:Availability>
+ <bpsim:FloatingParameter value="0"/>
+ </bpsim:Availability>
+ <bpsim:Quantity>
+ <bpsim:FloatingParameter value="0"/>
+ </bpsim:Quantity>
+ </bpsim:ResourceParameters>
+ <bpsim:CostParameters>
+ <bpsim:UnitCost>
+ <bpsim:FloatingParameter value="0"/>
+ </bpsim:UnitCost>
+ </bpsim:CostParameters>
+ </bpsim:ElementParameters>
+ <bpsim:ElementParameters
elementRef="_353B670A-55FB-4B3B-A602-B0748D6C50D3">
+ <bpsim:TimeParameters>
+ <bpsim:ProcessingTime>
+ <bpsim:NormalDistribution mean="0" standardDeviation="0"/>
+ </bpsim:ProcessingTime>
+ </bpsim:TimeParameters>
+ <bpsim:ResourceParameters>
+ <bpsim:Availability>
+ <bpsim:FloatingParameter value="0"/>
+ </bpsim:Availability>
+ <bpsim:Quantity>
+ <bpsim:FloatingParameter value="0"/>
+ </bpsim:Quantity>
+ </bpsim:ResourceParameters>
+ <bpsim:CostParameters>
+ <bpsim:UnitCost>
+ <bpsim:FloatingParameter value="0"/>
+ </bpsim:UnitCost>
+ </bpsim:CostParameters>
+ </bpsim:ElementParameters>
+ </bpsim:Scenario>
+ </bpsim:BPSimData>
+ </bpmn2:extensionElements>
+ <bpmn2:source>_XZ5wMFmeED6ZMPmYwBas4A</bpmn2:source>
+ <bpmn2:target>_XZ5wMFmeED6ZMPmYwBas4A</bpmn2:target>
+ </bpmn2:relationship>
+</bpmn2:definitions>
\ No newline at end of file
diff --git
a/jbpm/jbpm-tests/src/test/java/org/jbpm/bpmn2/ScriptLambdaValidationTest.java
b/jbpm/jbpm-tests/src/test/java/org/jbpm/bpmn2/ScriptLambdaValidationTest.java
new file mode 100644
index 0000000000..ceb640bfd4
--- /dev/null
+++
b/jbpm/jbpm-tests/src/test/java/org/jbpm/bpmn2/ScriptLambdaValidationTest.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.jbpm.bpmn2;
+
+import org.jbpm.bpmn2.flow.BPMN2_LambdaExpressionParserModel;
+import org.jbpm.bpmn2.flow.BPMN2_LambdaExpressionParserProcess;
+import org.jbpm.test.utils.ProcessTestHelper;
+import org.junit.jupiter.api.Test;
+import org.kie.kogito.Application;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+public class ScriptLambdaValidationTest extends JbpmBpmn2TestCase {
+
+ @Test
+ public void testLambdaScriptParser() {
+ Application app = ProcessTestHelper.newApplication();
+
+ org.kie.kogito.process.Process<BPMN2_LambdaExpressionParserModel>
minimalProcess = BPMN2_LambdaExpressionParserProcess.newProcess(app);
+ BPMN2_LambdaExpressionParserModel model = minimalProcess.createModel();
+
org.kie.kogito.process.ProcessInstance<BPMN2_LambdaExpressionParserModel>
instance = minimalProcess.createInstance(model);
+ instance.start();
+ var vars = instance.variables().toMap();
+ var vp = (org.jbpm.bpmn2.objects.User) vars.get("validPerson");
+ assertThat(vp).isNotNull();
+ assertThat(vp.getName()).isEqualTo("TestUser");
+
+ }
+}
diff --git
a/kogito-codegen-modules/kogito-codegen-processes/src/main/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidator.java
b/kogito-codegen-modules/kogito-codegen-processes/src/main/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidator.java
index 88798d0d11..3679e7c90c 100755
---
a/kogito-codegen-modules/kogito-codegen-processes/src/main/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidator.java
+++
b/kogito-codegen-modules/kogito-codegen-processes/src/main/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidator.java
@@ -44,6 +44,7 @@ import com.github.javaparser.ast.body.VariableDeclarator;
import com.github.javaparser.ast.expr.AssignExpr;
import com.github.javaparser.ast.expr.BinaryExpr;
import com.github.javaparser.ast.expr.Expression;
+import com.github.javaparser.ast.expr.LambdaExpr;
import com.github.javaparser.ast.expr.MethodCallExpr;
import com.github.javaparser.ast.expr.NameExpr;
import com.github.javaparser.ast.expr.VariableDeclarationExpr;
@@ -101,6 +102,8 @@ class JavaRuleFlowProcessValidator extends
RuleFlowProcessValidator {
Set<String> knownVariables = getKnownVariables(actionNode,
process);
// add local variables
unit.findAll(VariableDeclarationExpr.class).stream().flatMap(v
->
v.getVariables().stream()).map(VariableDeclarator::getNameAsString).forEach(knownVariables::add);
+ //add Support for lambda expressions
+ unit.findAll(LambdaExpr.class).forEach(le ->
le.getParameters().forEach(p -> knownVariables.add(p.getNameAsString())));
resolveVariablesType(unit, knownVariables);
} catch (UnsolvedSymbolException ex) {
if (LOGGER.isErrorEnabled()) {
diff --git
a/kogito-codegen-modules/kogito-codegen-processes/src/test/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidatorTest.java
b/kogito-codegen-modules/kogito-codegen-processes/src/test/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidatorTest.java
index 6d2602461a..20bbbedf60 100644
---
a/kogito-codegen-modules/kogito-codegen-processes/src/test/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidatorTest.java
+++
b/kogito-codegen-modules/kogito-codegen-processes/src/test/java/org/kie/kogito/codegen/process/JavaRuleFlowProcessValidatorTest.java
@@ -132,4 +132,54 @@ public class JavaRuleFlowProcessValidatorTest {
.isThrownBy(() -> validator.validate(process));
}
+ @Test
+ public void testScriptWithLambdaParameterRecognized() {
+ // 'i' is declared by the lambda validator should NOT complain
+ String script =
+ "java.util.List<Integer> list =
java.util.Arrays.asList(1,2,3);" +
+ "Integer first = list.stream().filter(i -> i >
0).findFirst().orElse(null);";
+
+ RuleFlowProcessFactory factory =
RuleFlowProcessFactory.createProcess("demo.lambda.ok");
+ factory
+ .name("lambda")
+ .packageName("com.myspace.demo")
+ .dynamic(false)
+ .version("1.0")
+ .startNode(one).name("start").done()
+ .actionNode(two).name("Lambda")
+ .action("java", script).done()
+ .endNode(three).name("end").terminate(false).done()
+ .connection(one, two).connection(two, three);
+
+ RuleFlowProcess process = factory.getProcess();
+ ProcessValidator validator =
ProcessValidatorRegistry.getInstance().getValidator(process, null);
+ assertThatNoException().isThrownBy(() -> validator.validate(process));
+ }
+
+ @Test
+ public void testScriptWithUnknownVariableInsideLambdaFails() {
+ // 'j' is NOT declared anywhere validator should still catch unknowns
+ String script =
+ "java.util.List<Integer> list =
java.util.Arrays.asList(1,2,3);" +
+ "list.stream().filter(i -> j >
0).findFirst().orElse(null);";
+
+ RuleFlowProcessFactory factory =
RuleFlowProcessFactory.createProcess("demo.lambda.bad");
+ factory
+ .name("lambda-exception")
+ .packageName("com.myspace.demo")
+ .dynamic(false)
+ .version("1.0")
+ .startNode(one).name("start").done()
+ .actionNode(two).name("Lambda")
+ .action("java", script).done()
+ .endNode(three).name("end").terminate(false).done()
+ .connection(one, two).connection(two, three);
+
+ RuleFlowProcess process = factory.getProcess();
+ ProcessValidator validator =
ProcessValidatorRegistry.getInstance().getValidator(process, null);
+ assertThatExceptionOfType(ValidationException.class)
+ .isThrownBy(() -> validator.validate(process))
+ .withMessageContaining("uses unknown variable in the script:
j");
+ }
+
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]