diff --git a/util/src/main/java/org/creekservice/api/test/util/coverage/CodeCoverage.java b/util/src/main/java/org/creekservice/api/test/util/coverage/CodeCoverage.java index 6f33f2c..47dbc32 100644 --- a/util/src/main/java/org/creekservice/api/test/util/coverage/CodeCoverage.java +++ b/util/src/main/java/org/creekservice/api/test/util/coverage/CodeCoverage.java @@ -21,7 +21,6 @@ import java.lang.management.RuntimeMXBean; import java.nio.file.Path; import java.util.Optional; -import java.util.regex.Pattern; /** Util class for capturing code coverage specific JVM arguments. */ @SuppressWarnings("OptionalUsedAsFieldOrParameterType") @@ -70,8 +69,7 @@ static Optional codeCoverageCmdLineArg( found.map( arg -> arg.replaceAll( - "([:=])build" - + Pattern.quote(File.separator), + "([:=])build[/\\\\]", "$1" + dir.toAbsolutePath() + File.separator)))