Repository navigation
58 lines (54 loc) · 1.56 KB
/
Copy pathnf-test.yml
File metadata and controls
58 lines (54 loc) · 1.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: nf-test
on:
push:
branches: [main, dev, 'nf-core/**']
pull_request:
branches: [main, dev]
workflow_dispatch:
concurrency:
group: "${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}"
cancel-in-progress: true
jobs:
changes:
name: Check changes
runs-on: ubuntu-latest
outputs:
nf_test_files: ${{ steps.list.outputs.components }}
has_changes: ${{ steps.list.outputs.has_changes }}
steps:
- uses: actions/checkout@v4
- name: List nf-test files
id: list
uses: ./.github/actions/get-shards
test:
name: "Test ${{ matrix.shard }}"
needs: changes
if: needs.changes.outputs.has_changes == 'true'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
shard: ${{ fromJson(needs.changes.outputs.nf_test_files) }}
profile: [docker]
NXF_VER:
- "24.04.2"
- "latest-everything"
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/nf-test
with:
shard: ${{ matrix.shard }}
profile: ${{ matrix.profile }}
nextflow_version: ${{ matrix.NXF_VER }}
confirm:
name: nf-test-success
if: always()
needs: [changes, test]
runs-on: ubuntu-latest
steps:
- name: All tests passed
if: needs.test.result == 'success' || needs.changes.outputs.has_changes != 'true'
run: echo "All tests passed"
- name: Some tests failed
if: needs.test.result != 'success' && needs.changes.outputs.has_changes == 'true'
run: exit 1