Skip to content

Commit

Permalink
ci: skip spl test when version is too high (#1945)
Browse files Browse the repository at this point in the history
(cherry picked from commit 4d9d27f)

# Conflicts:
#	.github/workflows/downstream-project-spl.yml
  • Loading branch information
yihau authored and mergify[bot] committed Jul 2, 2024
1 parent 73c7150 commit c5f45b6
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/scripts/downstream-project-spl-common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ project_used_solana_version=$(sed -nE 's/solana-sdk = \"[>=<~]*(.*)\"/\1/p' <"to
echo "used solana version: $project_used_solana_version"
if semverGT "$project_used_solana_version" "$SOLANA_VER"; then
echo "skip"
export SKIP_SPL_DOWNSTREAM_PROJECT_TEST=1
return
fi

Expand Down
15 changes: 15 additions & 0 deletions .github/workflows/downstream-project-spl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,13 @@ jobs:
- shell: bash
run: |
source .github/scripts/downstream-project-spl-common.sh
<<<<<<< HEAD
source .github/scripts/downstream-project-spl-install-deps.sh
=======
if [ -n "$SKIP_SPL_DOWNSTREAM_PROJECT_TEST" ]; then
exit 0
fi
>>>>>>> 4d9d27f1ff (ci: skip spl test when version is too high (#1945))

cargo check

Expand Down Expand Up @@ -102,7 +108,13 @@ jobs:
- shell: bash
run: |
source .github/scripts/downstream-project-spl-common.sh
<<<<<<< HEAD
source .github/scripts/downstream-project-spl-install-deps.sh
=======
if [ -n "$SKIP_SPL_DOWNSTREAM_PROJECT_TEST" ]; then
exit 0
fi
>>>>>>> 4d9d27f1ff (ci: skip spl test when version is too high (#1945))

programStr="${{ tojson(matrix.arrays.required_programs) }}"
IFS=', ' read -ra programs <<<"${programStr//[\[\]$'\n'$'\r' ]/}"
Expand Down Expand Up @@ -153,6 +165,9 @@ jobs:
- shell: bash
run: |
source .github/scripts/downstream-project-spl-common.sh
if [ -n "$SKIP_SPL_DOWNSTREAM_PROJECT_TEST" ]; then
exit 0
fi
programStr="${{ tojson(matrix.programs) }}"
IFS=', ' read -ra programs <<<"${programStr//[\[\]$'\n'$'\r' ]/}"
Expand Down

0 comments on commit c5f45b6

Please sign in to comment.