Skip to content

Commit

Permalink
MAINT: Moving linux CI to a separate workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
kmilo9999 committed Jun 14, 2024
1 parent aef457b commit 8e3a43a
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/linux_unit_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Unit tests

on:
push:
branches: ['**']
pull_request:
branches: ['**']

jobs:
build:

runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.8,3.9]

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install ubuntu dependencies
shell: bash -el {0}
run: |
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install libopenmpi-dev openmpi-bin
- name: Install dependencies
shell: bash -el {0}
run: |
python -m pip install --upgrade pip
python -m pip install mpi4py openmpi
- name: Install HNN-core
shell: bash -el {0}
run: |
python -m pip install --verbose '.[opt, parallel, test, gui]'
- name: Lint with flake8
shell: bash -el {0}
run: |
flake8 --count hnn_core
- name: Test with pytest
shell: bash -el {0}
run: |
python -m pytest ./hnn_core/tests/ --cov=hnn_core --cov-report=xml
- name: Upload coverage to Codecov
shell: bash -el {0}
run: |
bash <(curl -s https://codecov.io/bash) -f ./coverage.xml
File renamed without changes.

0 comments on commit 8e3a43a

Please sign in to comment.