forked from ilastik/volumina
-
Notifications
You must be signed in to change notification settings - Fork 0
84 lines (81 loc) · 2.62 KB
/
test.yml
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: test
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
test-w-ilastik-env:
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: checkout
uses: actions/checkout@v2
with:
# for codecov
fetch-depth: 5
- name: setup conda
uses: conda-incubator/setup-miniconda@v2
with:
environment-file: .github/workflows/etc/ilastik-env.yaml
activate-environment: ilastik-env
auto-update-conda: true
auto-activate-base: false
- name: linux test
if: matrix.os == 'ubuntu-latest'
shell: bash -l {0}
run: |
conda develop .
xvfb-run pytest --cov-report=xml --cov=volumina
- name: osx test
if: matrix.os == 'macos-latest'
shell: bash -l {0}
run: |
conda develop .
pytest
- name: windows test
if: matrix.os == 'windows-latest'
shell: cmd /C CALL {0}
# auto activation of env does not seem to work on win
run: |
conda activate ilastik-env & python --version & conda list & conda develop . & pytest
- uses: codecov/codecov-action@v1
if: matrix.os == 'ubuntu-latest'
with:
files: ./coverage.xml,
fail_ci_if_error: true # optional (default = false)
verbose: true # optional (default = false)
test-w-conda-recipe:
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: checkout
uses: actions/checkout@v2
- name: setup conda
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
auto-activate-base: true
activate-environment: ""
- name: linux conda build test
if: matrix.os == 'ubuntu-latest'
shell: bash -l {0}
run: |
conda install -n base -c conda-forge conda-build setuptools_scm -y
xvfb-run conda build -c conda-forge conda-recipe
- name: osx test
if: matrix.os == 'macos-latest'
shell: bash -l {0}
run: |
conda install -n base -c conda-forge conda-build setuptools_scm -y
conda build -c conda-forge conda-recipe
- name: windows conda-build
if: matrix.os == 'windows-latest'
shell: cmd /C CALL {0}
# auto activation of env does not seem to work on win
run: |
conda install -n base -c conda-forge conda-build setuptools_scm -y & conda build -c conda-forge conda-recipe