-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (35 loc) · 1.11 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
# Perform some basic linting to for syntax errors and undefined names, then run the test suite.
name: Tests
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
container:
image: cmacmackin/nekpy:latest
steps:
- uses: actions/checkout@v3
- name: Update PATH
run: echo "/opt/view/bin" >> $GITHUB_PATH
- name: Cache pip-installed packages
uses: actions/cache@v3
with:
path: |
/usr/local/bin/python3.10/dist-packages/
~/.cache/sphinx_immaterial
key: ${{ runner.os }}-${{ hashFiles('setup.py', 'docs/requirements.txt') }}
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements-dev.txt
python3 -m pip install .
- name: Test with pytest
run: |
pytest --cov --cov-report=xml --hypothesis-profile ci
- name: Upload coverage reports to Codecov with GitHub Action
uses: codecov/codecov-action@v3