-
Notifications
You must be signed in to change notification settings - Fork 194
42 lines (40 loc) · 1.2 KB
/
test_conda.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
name: CI
# thanks for @mpariente for copying this workflow
# see: https://help.github.com/en/actions/reference/events-that-trigger-workflows
# Trigger the workflow on push or pull request
on: [push, pull_request]
jobs:
src-test:
name: conda-tests
runs-on: ubuntu-latest
# Timeout: https://stackoverflow.com/a/59076067/4521646
timeout-minutes: 10
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v2
- name: Cache conda
uses: actions/cache@v2
with:
path: ~/conda_pkgs_dir
key: conda-${{ hashFiles('environment-ci.yml') }}
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
with:
activate-environment: umx-cpu
environment-file: scripts/environment-cpu-linux.yml
auto-update-conda: true
auto-activate-base: false
python-version: 3.7
- name: Install dependencies
run: |
python -m pip install -e .['tests']
python --version
pip --version
python -m pip list
- name: Conda list
run: conda list
- name: Run model test
run: |
py.test tests/test_model.py -v