Unverified Commit d2bb5a81 authored by Copilot's avatar Copilot Committed by GitHub
Browse files

Fix failing GitHub Actions job for graalvm 24-ea (#1227)

* Initial plan

* Normalize EA setup-java version output in verify-java.sh

Co-authored-by: default avatarbrunoborges <[email protected]>

---------

Co-authored-by: default avatarcopilot-swe-agent[bot] <[email protected]>
Co-authored-by: default avatarbrunoborges <[email protected]>
Co-authored-by: default avatarBruno Borges <[email protected]>
parent a52a3de6
Loading
Loading
Loading
Loading
+3
Changes for __tests__/verify-java.sh: 3 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -35,6 +35,9 @@ fi

if [ -n "$SETUP_JAVA_VERSION" ]; then
  OUTPUT_JAVA_VERSION=$(echo "$SETUP_JAVA_VERSION" | cut -d'+' -f1)
  if [[ $OUTPUT_JAVA_VERSION == *-ea* ]]; then
    OUTPUT_JAVA_VERSION=$(echo "$OUTPUT_JAVA_VERSION" | cut -d'-' -f1 | cut -d'.' -f1)
  fi
  OUTPUT_GREP_RESULT=$(echo "$ACTUAL_JAVA_VERSION" | grep -E "^(openjdk|java) version \"$OUTPUT_JAVA_VERSION")
  if [ -z "$OUTPUT_GREP_RESULT" ]; then
    echo "::error::The version output does not match the installed Java version"