Skip to content

Commit

Permalink
Merge pull request #2 from common-workflow-lab/add-tags
Browse files Browse the repository at this point in the history
Add `tags` option
  • Loading branch information
tom-tan authored Mar 30, 2022
2 parents 4b0e6e2 + cbda385 commit 2add3a2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
| `cwlVersion` | true | - | target CWL version |
| `runner` | true | - | full path to CWL runner to be tested |
| `timeout` | false | 30 | timeout in seconds |
| `tags` | false | "" | tags to be tested (e.g., "docker,required") |
| `skip-python-install` | false | false | skip installing python interpreter |

The `skip-python-install` parameter is useful when CWL runner requires specific version of Python.
Expand Down
12 changes: 10 additions & 2 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ inputs:
description: 'skip installing python interpreter'
required: false
default: false
# TODO: EXTRA, -n, -j, --tags
tags:
description: 'tags to be tested (e.g., "docker,required")'
required: false
# TODO: EXTRA, -n, -j
outputs:
badgedir:
description: 'The directory name that stores conformance badges'
Expand Down Expand Up @@ -72,7 +75,12 @@ runs:
else
basedir=.
fi
./run_test.sh RUNNER=${{inputs.runner}} --badgedir=$basedir/badges --junit-xml=$basedir/junit.xml --timeout=${{inputs.timeout}} || true
if [ -n "${{ inputs.tags }}" ]; then
tagopt="--tags=${{ inputs.tags }}"
fi
./run_test.sh RUNNER=${{inputs.runner}} --badgedir=$basedir/badges --junit-xml=$basedir/junit.xml --timeout=${{inputs.timeout}} $tagopt || true
echo "::set-output name=badgedir::$GITHUB_WORKSPACE/cwl-run-conformance-${{ inputs.cwlVersion }}/badges"
echo "::set-output name=result::$GITHUB_WORKSPACE/cwl-run-conformance-${{ inputs.cwlVersion }}/junit.xml"
env:
Expand Down

0 comments on commit 2add3a2

Please sign in to comment.