Substrate currently fails for some GraalVM builds that print versions without minor revision numbers, e.g., graalvm-jdk-21+35.1/bin/java -version
java version "21" 2023-09-19
Java(TM) SE Runtime Environment Oracle GraalVM 21+35.1 (build 21+35-jvmci-23.1-b15)
Java HotSpot(TM) 64-Bit Server VM Oracle GraalVM 21+35.1 (build 21+35-jvmci-23.1-b15, mixed mode, sharing)
This PR changes the Regex from GraalVM .*?(\d\d.\d.\d) to GraalVM (\d{1,2}(\.\d+){0,2}) (same as for the Java version) and adds unit tests for a variety of old and new GraalVM builds on different platforms
Substrate currently fails for some GraalVM builds that print versions without minor revision numbers, e.g.,
graalvm-jdk-21+35.1/bin/java -version
This PR changes the Regex from
GraalVM .*?(\d\d.\d.\d)
toGraalVM (\d{1,2}(\.\d+){0,2})
(same as for the Java version) and adds unit tests for a variety of old and new GraalVM builds on different platformsCurrent Regex
GraalVM .*?(\d\d.\d.\d)
Updated Regex
GraalVM (\d{1,2}(.\d+){0,2})