-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (53 loc) · 1.61 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
51
52
53
54
55
name: Build and test Glia
on: [push]
jobs:
build:
name: build py${{ matrix.py }}, NEURON ${{ matrix.nrn }}
runs-on: ubuntu-latest
strategy:
matrix:
py: ["3.9", "3.10"]
nrn: ["8.1.0", "8.2.3"]
include:
- py: "3.9"
nrn: "8.0.2"
- py: "3.11"
nrn: "8.2.3"
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.py }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.py }}
- name: Install apt dependencies
run: |
sudo apt-get update
sudo apt-get install openmpi-bin libopenmpi-dev
- name: Cache pip
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }}
restore-keys: |
${{ runner.os }}-pip-
${{ runner.os }}-
- name: Install dependencies & self
run: |
python -m pip install --upgrade pip
pip install .[test,parallel,neuron,arbor]
pip install NEURON==${{ matrix.nrn }}
- name: Run package-free tests
run: coverage run -p -m unittest -v
- name: Install test package
run: pip install ./tests/data/packages/glia_test_mods
- name: Run serial tests
run: coverage run -p -m unittest -v
- name: Run parallel tests
run: mpiexec -n 2 coverage run -p -m unittest -v
- name: Test local package
run: |
glia pkg add ./tests/data/mods/Na__0.mod --local
glia compile
glia test Na
- name: Upload coverage reports
run: bash <(curl -s https://codecov.io/bash)