修复windows场景下无法解析模糊路径的bug

This commit is contained in:
rain
2024-04-24 21:23:48 +08:00
parent 252c81dd15
commit 3a25c35b62
7 changed files with 62 additions and 2 deletions

View File

@@ -50,6 +50,16 @@ public class AbsoluteConfigPathTest extends BaseTest {
});
}
@Test
public void testAbsPath() throws Exception{
Assertions.assertTrue(() -> {
LiteflowConfig config = new LiteflowConfig();
config.setRuleSource(StrUtil.format("{}\\sub\\**\\*.xml",rootDir));
flowExecutor = FlowExecutorHolder.loadInstance(config);
return flowExecutor.execute2Resp("chain1", "arg").isSuccess();
});
}
@BeforeAll
public static void createFiles() {
rootDir = FileUtil.getAbsolutePath(ResourceUtil.getResource("").getPath());