Skip to content

Commit 5d4d3e3

Browse files
committed
Add codecov
1 parent 266302e commit 5d4d3e3

File tree

3 files changed

+25
-2
lines changed

3 files changed

+25
-2
lines changed

.github/workflows/ci.yml

+8-2
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,11 @@ jobs:
3636
python-version: ${{ matrix.python-version }}
3737
- name: Run tests
3838
run: |
39-
make init
40-
make test
39+
pip install -e .[test]
40+
pytest --cov-report=xml --no-cov-on-fail
41+
- name: Upload coverage to Codecov
42+
uses: codecov/codecov-action@v3
43+
with:
44+
token: ${{ secrets.CODECOV_TOKEN }} # use token for more robust uploads
45+
name: ${{ matrix.python-version }}
46+
fail_ci_if_error: false

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
![Read the Docs](https://img.shields.io/readthedocs/causalpy)
88
![PyPI - Downloads](https://img.shields.io/pypi/dm/causalpy)
99
![Interrogate](img/interrogate_badge.svg)
10+
[![codecov](https://codecov.io/gh/pymc-labs/CausalPy/branch/main/graph/badge.svg?token=FDKNAY5CZ9)](https://codecov.io/gh/pymc-labs/CausalPy)
1011

1112
A Python package focussing on causal inference in quasi-experimental settings. The package allows for sophisticated Bayesian model fitting methods to be used in addition to traditional OLS.
1213

codecov.yml

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
coverage:
2+
status:
3+
project:
4+
default:
5+
# basic
6+
target: auto
7+
threshold: 2%
8+
base: auto
9+
paths:
10+
- "causalpy/"
11+
# advanced settings
12+
branches:
13+
- main
14+
if_ci_failed: error #success, failure, error, ignore
15+
informational: false
16+
only_pulls: false

0 commit comments

Comments
 (0)