-
Notifications
You must be signed in to change notification settings - Fork 7
80 lines (68 loc) · 1.95 KB
/
gh-ci.yaml
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
name: GH Actions CI
on:
push:
branches:
- master
pull_request:
branches:
- master
schedule:
# 3 am Tuesdays and Fridays
- cron: "0 3 * * 2,5"
concurrency:
group: "${{ github.ref }}-${{ github.head_ref }}-${{ github.workflow }}"
cancel-in-progress: true
defaults:
run:
shell: bash
jobs:
unittests:
if: "github.repository == 'MDAnalysis/panedr'"
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, ]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
include:
- os: windows-latest
python-version: "3.13"
- os: macos-latest
python-version: "3.13"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: install optional deps
run: |
pip install pytest pytest-xdist pytest-cov
- name: install pyedr package
run: |
cd pyedr && python -m pip install -e .
pip list
- name: run pyedr tests
run: |
pytest -n 2 -v --cov=pyedr/pyedr --cov-report=xml --color=yes pyedr/pyedr/tests
- name: install panedr package
run: |
pip install pandas
cd panedr && pip install -e .
- name: run panedr tests
run: |
pytest -n2 -v --cov=panedr/panedr --cov-report=xml --color=yes --cov-append panedr/panedr/tests
- name: test imports
# Exit the git repo in order for pbr to stop auto-picking up version info
# from the local git data
working-directory: ../
run: |
python -Ic "from pyedr import edr_to_dict"
python -Ic "from panedr import edr_to_df"
- name: codecov
if: ${{ github.event_name != 'schedule' }}
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage.xml
fail_ci_if_error: True
verbose: True