-
Notifications
You must be signed in to change notification settings - Fork 58
50 lines (45 loc) · 1.18 KB
/
main.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
name: Tests
on:
push:
branches:
- main
pull_request:
branches-ignore: []
schedule:
- cron: '0 0 * * SUN'
jobs:
build-linux:
runs-on: ubuntu-latest
strategy:
max-parallel: 5
matrix:
python: [3.7, 3.8, 3.9]
fail-fast: false
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.X
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python }}
- name: conda
run: |
# $CONDA is an environment variable pointing to the root of the miniconda directory
echo $CONDA/bin >> $GITHUB_PATH
- name: Install dependencies
run: |
conda install -c conda-forge mamba --quiet
mamba install -c conda-forge --quiet -y --file=requirements.txt --file=requirements_dev.txt
- name: Install the package itself
run: |
pip install .
- name: Test with pytest
run: |
pip install pytest
pip install pytest-cov
pytest --cov-report term --cov=fitter
- name: coveralls
run: |
pip install coverage
coveralls --service=github
env:
GITHUB_TOKEN: ${{ github.token }}