File tree Expand file tree Collapse file tree 2 files changed +45
-0
lines changed Expand file tree Collapse file tree 2 files changed +45
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Continuous Integration Tests Draft PR (pytest)
2
+ # This duplicate ci workflow is required so the badge in the README.md is not effected by draft PRs
3
+ on :
4
+ pull_request :
5
+ branches :
6
+ - main
7
+
8
+ jobs :
9
+ build :
10
+ if : github.event.pull_request.draft == true
11
+ name : Ex1 (${{ matrix.python-version }}, ${{ matrix.os }})
12
+ runs-on : ${{ matrix.os }}
13
+ strategy :
14
+ matrix :
15
+ os : ["ubuntu-latest", "windows-latest", "macos-latest"]
16
+ python-version : ["3.9"]
17
+ steps :
18
+ - uses : actions/checkout@v2
19
+ - name : Set up Python using Miniconda
20
+ uses : conda-incubator/setup-miniconda@v2
21
+ with :
22
+ auto-update-conda : true
23
+ python-version : ${{ matrix.python-version }}
24
+ - name : Install package and dependencies
25
+ run : |
26
+ python --version
27
+ pip install -e .
28
+ pip install -e .[test]
29
+ pip install pytest pytest-cov
30
+ shell : bash -l {0}
31
+ - name : Test with pytest
32
+ run : |
33
+ pytest --cov=causal_testing --cov-report=xml
34
+ shell : bash -l {0}
35
+ - name : " Upload coverage to Codecov"
36
+ uses : codecov/codecov-action@v2
37
+ with :
38
+ fail_ci_if_error : true
39
+ token : ${{ secrets.CODECOV_TOKEN }}
Original file line number Diff line number Diff line change 4
4
pull_request :
5
5
branches :
6
6
- main
7
+ types :
8
+ - opened
9
+ - synchronize
10
+ - reopened
11
+ - ready_for_review
7
12
8
13
jobs :
9
14
build :
15
+ if : github.event.pull_request.draft == false # Filter out draft PRs
10
16
name : Ex1 (${{ matrix.python-version }}, ${{ matrix.os }})
11
17
runs-on : ${{ matrix.os }}
12
18
strategy :
You can’t perform that action at this time.
0 commit comments