Skip to content

Commit 6d24068

Browse files
author
Gonzalo Diaz
committed
[CONFIG] Node script for github-actions. Split in 2: One for Coverage, the another to run multi-version/multi-OS tests.
1 parent 80227ef commit 6d24068

File tree

2 files changed

+47
-7
lines changed

2 files changed

+47
-7
lines changed

.github/workflows/python-coverage.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Python CI Tests
2+
3+
on:
4+
push:
5+
branches: [ "main", "develop", "feature/*" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
env:
10+
LOG_LEVEL: INFO
11+
12+
jobs:
13+
14+
build:
15+
name: "Run CI"
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
os: ["ubuntu-latest"]
20+
python: ['3.12']
21+
runs-on: ${{ matrix.os }}
22+
steps:
23+
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4
24+
25+
- name: Setup Python
26+
uses: actions/setup-python@master
27+
with:
28+
python-version: ${{ matrix.python }}
29+
30+
- name: Install
31+
run: |
32+
pip3 install -r requirements.txt
33+
34+
- name: Test
35+
run: |
36+
coverage run -m pytest --verbose -o log_cli=true --log-cli-level=INFO src/
37+
38+
- name: Coverage
39+
run: |
40+
coverage report
41+
42+
- name: Upload coverage reports to Codecov with GitHub Action
43+
uses: codecov/codecov-action@v4
44+
with:
45+
token: ${{ secrets.CODECOV_TOKEN }} # required
46+
verbose: true # optional (default = false)

.github/workflows/python.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Python
1+
name: Python CI Tests
22

33
on:
44
push:
@@ -58,9 +58,3 @@ jobs:
5858
- name: Coverage
5959
run: |
6060
coverage report
61-
62-
- name: Upload coverage reports to Codecov with GitHub Action
63-
uses: codecov/codecov-action@v4
64-
with:
65-
token: ${{ secrets.CODECOV_TOKEN }} # required
66-
verbose: true # optional (default = false)

0 commit comments

Comments
 (0)