Skip to content

Commit 40aac67

Browse files
committed
Merge branch 'github-actions-conda_revised' into github-actions-conda
2 parents 5bb9de4 + b7b696f commit 40aac67

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed

.coveragerc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
[run]
22
source = control
33
omit = control/tests/*
4+
relative_files = True
45

56
[report]
67
exclude_lines =

.github/workflows/python-package-conda.yml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Conda-based pytest
33
on: [push, pull_request]
44

55
jobs:
6-
build-linux:
6+
test-linux:
77
runs-on: ubuntu-latest
88

99
strategy:
@@ -19,6 +19,7 @@ jobs:
1919

2020
steps:
2121
- uses: actions/checkout@v2
22+
2223
- name: Install dependencies
2324
run: |
2425
# Set up conda
@@ -31,18 +32,36 @@ jobs:
3132
3233
# Install test tools
3334
conda install pip coverage pytest
34-
conda install -c conda-forge pytest-cov
35+
pip install coveralls
3536
3637
# Install python-control dependencies
3738
conda install numpy matplotlib scipy
3839
if [[ '${{matrix.slycot}}' == 'conda' ]]; then
3940
conda install -c conda-forge slycot
4041
fi
42+
4143
- name: Test with pytest
4244
env:
4345
PYTHON_CONTROL_ARRAY_AND_MATRIX: ${{ matrix.array-and-matrix }}
4446
run: |
4547
source $CONDA/bin/activate test-environment
4648
# Use xvfb-run instead of pytest-xvfb to get proper mpl backend
49+
# Use coverage instead of pytest-cov to get .coverage file
4750
# See https://github.com/python-control/python-control/pull/504
48-
xvfb-run --auto-servernum pytest control/tests
51+
xvfb-run --auto-servernum coverage run -m pytest control/tests
52+
53+
- name: Coveralls parallel
54+
# https://github.com/coverallsapp/github-action
55+
uses: AndreMiras/coveralls-python-action@develop
56+
with:
57+
parallel: true
58+
59+
coveralls:
60+
name: coveralls completion
61+
needs: test-linux
62+
runs-on: ubuntu-latest
63+
steps:
64+
- name: Coveralls Finished
65+
uses: AndreMiras/coveralls-python-action@develop
66+
with:
67+
parallel-finished: true

0 commit comments

Comments
 (0)