From eb007865e593d06e2766b9e3083c28439757c4e1 Mon Sep 17 00:00:00 2001 From: Mike Barry Date: Sun, 19 May 2024 16:39:22 -0400 Subject: [PATCH] debug --- .../test/java/com/onthegomap/planetiler/util/GlobTest.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/planetiler-core/src/test/java/com/onthegomap/planetiler/util/GlobTest.java b/planetiler-core/src/test/java/com/onthegomap/planetiler/util/GlobTest.java index df66bb8813..edc33f38c3 100644 --- a/planetiler-core/src/test/java/com/onthegomap/planetiler/util/GlobTest.java +++ b/planetiler-core/src/test/java/com/onthegomap/planetiler/util/GlobTest.java @@ -1,6 +1,7 @@ package com.onthegomap.planetiler.util; import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertTrue; import java.io.IOException; import java.nio.file.FileSystems; @@ -42,6 +43,9 @@ void testWalkPathWithPattern() throws IOException { var path = tmpDir.resolve("a").resolve("b").resolve("c.txt"); FileUtils.createParentDirectories(path); Files.writeString(path, "test"); + var sep = path.getFileSystem().getSeparator(); + assertTrue( + path.getFileSystem().getPathMatcher("*" + sep + "*" + sep + "c.txt").matches(Path.of("a", "b", "c.txt"))); assertEquals(List.of(path), Glob.of(tmpDir).resolve("a", "*", "c.txt").find()); System.err.println(Glob.of(tmpDir).resolve("*", "*", "c.txt")); System.err.println(Glob.of(tmpDir).resolve("*", "*", "c.txt").find()); // nope