From cf0ab41d38589f3134ae94684541352a3cc1e025 Mon Sep 17 00:00:00 2001 From: zy <953725892@qq.com> Date: Wed, 27 Sep 2023 19:26:00 +0800 Subject: [PATCH] =?UTF-8?q?test=20#I7SVZF=20=E6=96=B0=E5=A2=9E=E6=96=B0?= =?UTF-8?q?=E5=91=BD=E5=90=8D=E8=A7=84=E5=88=99=E4=B8=8B=E6=B5=8B=E8=AF=95?= =?UTF-8?q?=E7=94=A8=E4=BE=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AbstractChainJsonELSpringBootTest.java | 7 +++++++ .../AbstractChainXmlELSpringbootTest.java | 7 +++++++ .../src/test/resources/abstractChain/flow.el.xml | 14 +++++++++++++- 3 files changed, 27 insertions(+), 1 deletion(-) diff --git a/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainJsonELSpringBootTest.java b/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainJsonELSpringBootTest.java index 63d25911c..38f2ea997 100644 --- a/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainJsonELSpringBootTest.java +++ b/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainJsonELSpringBootTest.java @@ -50,4 +50,11 @@ public class AbstractChainJsonELSpringBootTest extends BaseTest { Assertions.assertEquals("a==>b==>a==>b==>a==>b==>f==>a==>b", response.getExecuteStepStrWithoutTime()); } + @Test + public void test4() throws Exception { + LiteflowResponse response = flowExecutor.execute2Resp("implD", "arg"); + Assertions.assertTrue(response.isSuccess()); + Assertions.assertEquals("a==>b==>j==>k==>c==>d==>f==>j", response.getExecuteStepStrWithoutTime()); + } + } diff --git a/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainXmlELSpringbootTest.java b/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainXmlELSpringbootTest.java index efc11bec2..8a6b52be7 100644 --- a/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainXmlELSpringbootTest.java +++ b/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/java/com/yomahub/liteflow/test/abstractChain/AbstractChainXmlELSpringbootTest.java @@ -52,4 +52,11 @@ public class AbstractChainXmlELSpringbootTest extends BaseTest { Assertions.assertEquals("a==>b==>a==>b==>a==>b==>f==>a==>b", response.getExecuteStepStrWithoutTime()); } + @Test + public void test4() throws Exception { + LiteflowResponse response = flowExecutor.execute2Resp("implD", "arg"); + Assertions.assertTrue(response.isSuccess()); + Assertions.assertEquals("a==>b==>a==>b==>j==>k==>c==>d==>f==>j", response.getExecuteStepStrWithoutTime()); + } + } diff --git a/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/resources/abstractChain/flow.el.xml b/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/resources/abstractChain/flow.el.xml index e55fdc839..1b1ded112 100644 --- a/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/resources/abstractChain/flow.el.xml +++ b/liteflow-testcase-el/liteflow-testcase-el-springboot/src/test/resources/abstractChain/flow.el.xml @@ -6,7 +6,7 @@ - {3}=THEN(a,b); + {3} = THEN(a,b); {4}=THEN(a,b).id("j"); @@ -23,4 +23,16 @@ {0}=THEN(a,b,{3}); {1}=SWITCH(f).to({4},k); + + + THEN({_pre},{mainChain}, {subChain1},{subChain2},{end_chain}) + + + + {_pre} = THEN(a,b); + {mainChain}=THEN(a,b); + {subChain1}=THEN(j,k); + {subChain2}=IF(c, d, e); + {end_chain}=SWITCH(f).to(j,k); + \ No newline at end of file