Skip to content

Commit

Permalink
ci: Copy ci from methylseq
Browse files Browse the repository at this point in the history
  • Loading branch information
edmundmiller committed Nov 7, 2022
1 parent 94e8147 commit 0db3e0e
Showing 1 changed file with 11 additions and 35 deletions.
46 changes: 11 additions & 35 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ env:

jobs:
test:
name: Run default pipeline test
name: Run ${{ matrix.profile }}-${{ matrix.NXF_VER }} pipeline test
# Only run on push if this is the nf-core dev branch (merged PRs)
if: "${{ github.event_name != 'push' || (github.event_name == 'push' && github.repository == 'nf-core/rnaseq') }}"
runs-on: ubuntu-latest
Expand All @@ -31,21 +31,6 @@ jobs:
- name: Check out pipeline code
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.x"

- uses: actions/cache@v2
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/cache@v2
with:
path: /usr/local/bin/nextflow
Expand All @@ -58,6 +43,11 @@ jobs:
with:
version: "${{ matrix.NXF_VER }}"

- name: Install nf-test
run: |
wget -qO- https://code.askimed.com/install/nf-test | bash
sudo mv nf-test /usr/local/bin/
- name: Set up Singularity
if: matrix.profile == 'singularity'
uses: eWaterCycle/setup-singularity@v5
Expand All @@ -76,24 +66,10 @@ jobs:
if: matrix.profile == 'conda'
run: conda clean -a

- name: Run pipeline with tests settings
run: TMPDIR=~ PROFILE=${{ matrix.profile }} pytest --tag default --symlink --kwdof --git-aware --color=yes

- name: Output log on failure
if: failure()
run: |
sudo apt-get install bat > /dev/null
batcat --decorations=always --color=always /home/runner/pytest_workflow_*/*/log.{out,err}
- name: Run nf-test
run: nf-test test --profile=${{ matrix.profile }} tests/pipeline/default/*.nf.test --tap=test.tap

- name: Upload logs on failure
if: failure()
uses: actions/upload-artifact@v2
- uses: pcolby/tap-summary@v1
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_*/*/work/conda
!/home/runner/pytest_workflow_*/*/work/singularity
path: >-
test.tap

0 comments on commit 0db3e0e

Please sign in to comment.