enhancement #I588BO 对Slot模型的重构,在用户使用中去除Slot模型的概念,引入上下文的概念

This commit is contained in:
bryan31
2022-06-03 00:34:00 +08:00
parent 622e324ec8
commit c1942a0171
2 changed files with 7 additions and 7 deletions

View File

@@ -42,8 +42,8 @@ public class FlowExecutorTest extends BaseTest {
LiteflowConfig config = new LiteflowConfig();
config.setRuleSource("executor/flow.json");
FlowExecutor executor = new FlowExecutor(config);
Slot<CustomContext> slot = executor.execute("chain1", "test0", CustomContext.class);
Assert.assertEquals("custom", slot.getContextBean().getName());
CustomContext context = executor.execute("chain1", "test0", CustomContext.class);
Assert.assertEquals("custom", context.getName());
}
@Test(expected=RuntimeException.class)