Skip to content

verified workflows: conditional-gate-on-nonempty-result #3

verified workflows: conditional-gate-on-nonempty-result

verified workflows: conditional-gate-on-nonempty-result #3

name: Verification workflows
on:
pull_request:
paths:
- "verification/workflows/**"
- "content/verification/**"
- ".github/workflows/verification-workflows.yml"
push:
branches: [main]
paths:
- "verification/workflows/**"
- "content/verification/**"
- ".github/workflows/verification-workflows.yml"
jobs:
planemo:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: false
channels: conda-forge,bioconda
channel-priority: strict
- name: Install Planemo
run: python -m pip install planemo==0.75.41
- name: Lint verified workflow
continue-on-error: true
shell: bash
run: |
set -euo pipefail
planemo --version
command -v planemo
mapfile -t workflows < <(git ls-files 'verification/workflows/**/*.gxwf.yml')
if [ "${#workflows[@]}" -eq 0 ]; then
echo "No verification workflows found" >&2
exit 1
fi
for workflow in "${workflows[@]}"; do
planemo lint "$workflow"
done
- name: Test verified workflow
shell: bash
run: |
set -euo pipefail
mkdir -p upload
mapfile -t workflows < <(git ls-files 'verification/workflows/**/*.gxwf.yml')
if [ "${#workflows[@]}" -eq 0 ]; then
echo "No verification workflows found" >&2
exit 1
fi
for workflow in "${workflows[@]}"; do
name="${workflow#verification/workflows/}"
name="${name//\//-}"
name="${name%.gxwf.yml}"
planemo test "$workflow" \
--galaxy_branch release_25.1 \
--test_output_json "upload/${name}.json" \
--test_output "upload/${name}.html" \
--summary minimal
done
- uses: actions/upload-artifact@v4
if: always()
with:
name: verification-workflows-planemo
path: upload/