updated python container #115
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Pytest-workflow | |
on: [push] | |
jobs: | |
test: | |
runs-on: ubuntu-20.04 | |
name: ${{ matrix.profile }} | |
strategy: | |
fail-fast: false | |
matrix: | |
profile: ["docker"] | |
env: | |
NXF_ANSI_LOG: false | |
steps: | |
- uses: actions/[email protected] | |
- name: Set up Python | |
uses: actions/[email protected] | |
with: | |
python-version: "3.x" | |
- uses: actions/[email protected] | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} | |
restore-keys: | | |
${{ runner.os }}-pip- | |
- name: Install Python dependencies | |
run: python -m pip install --upgrade pip pytest-workflow | |
- uses: actions/[email protected] | |
with: | |
path: /usr/local/bin/nextflow | |
key: ${{ runner.os }} | |
restore-keys: | | |
${{ runner.os }}-nextflow- | |
- name: Install Nextflow | |
env: | |
CAPSULE_LOG: none | |
run: | | |
wget -qO- get.nextflow.io | bash | |
sudo mv nextflow /usr/local/bin/ | |
# Test the pipeline | |
- name: Run pytest-workflow | |
# only use one thread for pytest-workflow to avoid race condition on conda cache. | |
run: TMPDIR=~ PROFILE=${{ matrix.profile }} pytest -vvv --symlink --kwdof --git-aware --color=yes | |
- name: Output log on failure | |
if: failure() | |
run: | | |
sudo apt-get update > /dev/null | |
sudo apt-get install bat > /dev/null | |
batcat --decorations=always --color=always /home/runner/pytest_workflow_*/*/log.{out,err} | |
- name: Upload logs on failure | |
if: failure() | |
uses: actions/[email protected] | |
with: | |
name: logs-${{ matrix.profile }} | |
path: | | |
/home/runner/pytest_workflow_*/*/.nextflow.log | |
/home/runner/pytest_workflow_*/*/log.out | |
/home/runner/pytest_workflow_*/*/log.err | |
/home/runner/pytest_workflow_*/*/work | |
/home/runner/pytest_workflow_*/*/results |