Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create test_bioimageio_resources.yaml #1

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 59 additions & 0 deletions .github/workflows/test_bioimageio_resources.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: test BioImage.IO resources # for compatibility with BioEngine model runner

concurrency: test-resources

on:
workflow_dispatch:
inputs:
pending_matrix:
description: 'json encoded gh matrix of pending validations for new or updated resources (default: test on all resources)'
required: true
default: '{"include": [{"resource_id": "**", "version_id": "**"}]}'
type: string

jobs:
run:
runs-on: ubuntu-latest
strategy:
matrix: ${{ fromJson(inputs.pending_matrix) }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v2 # checkout gh-pages to make sure we have access to latest deployment (raw.githubusercontent.com might be behind)
with:
repository: bioimage-io/collection-bioimage-io
ref: gh-pages
path: bioimageio-gh-pages

- name: test with docker container
run: |
mkdir -p dist/${{ matrix.resource_id }}/${{ matrix.version_id }}
echo 'TODO' > dist/${{ matrix.resource_id }}/${{ matrix.version_id }}/test_summary.yaml
echo 'TODO: generate test_summary using docker container'
- name: prepare artifact upload
run: echo ::set-output name=name::$(${{ matrix.resource_id }}${{ matrix.version_id }} | sed 's#/##g') # remove '/' from artifact name
- name: Upload test summaries
uses: actions/upload-artifact@v3
with:
name: ${{ prep_artifact.outputs.name }}
path: dist
retention-days: 1

deploy:
needs: run
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/download-artifact@v3
with:
path: artifacts
- name: merge test summaries # (they differ by path or postfix)
run: |
mkdir dist
cp -r artifacts/*/* dist
- name: Deploy test summaries to gh-pages 🚀
uses: JamesIves/[email protected]
with:
clean: false
branch: gh-pages
folder: dist