Skip to content

Commit

Permalink
try coverage for all libs
Browse files Browse the repository at this point in the history
Signed-off-by: Avik Basu <[email protected]>
  • Loading branch information
ab93 committed Jun 7, 2024
1 parent 348b4dc commit 5a2bfc0
Show file tree
Hide file tree
Showing 5 changed files with 89 additions and 1 deletion.
60 changes: 59 additions & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
branches: [ "main" ]

jobs:
build:
numalogic-core:
name: numalogic-core
runs-on: ubuntu-latest
defaults:
Expand Down Expand Up @@ -36,3 +36,61 @@ jobs:
files: ./coverage.xml
fail_ci_if_error: true
verbose: true
numalogic-connectors:
name: numalogic-connectors
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./libs/numalogic-connectors
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: 'pip'
- name: Install dependencies
working-directory: ./libs/numalogic-connectors
run: |
pip install -r requirements/requirements.txt
pip install -r requirements/requirements-dev.txt
- name: Run Coverage
run: pytest --cov-report=xml --cov=numalogic-connectors --cov-config .coveragerc tests/ -sq

- name: Upload Coverage
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
fail_ci_if_error: true
verbose: true
numalogic-registry:
name: numalogic-registry
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./libs/numalogic-registry
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: 'pip'
- name: Install dependencies
working-directory: ./libs/numalogic-registry
run: |
pip install -r requirements/requirements.txt
pip install -r requirements/requirements-dev.txt
- name: Run Coverage
run: pytest --cov-report=xml --cov=numalogic-registry --cov-config .coveragerc tests/ -sq

- name: Upload Coverage
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
fail_ci_if_error: true
verbose: true
10 changes: 10 additions & 0 deletions libs/numalogic-connectors/.codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
coverage:
status:
project:
default:
target: auto
threshold: 3%
patch:
default:
target: auto
threshold: 20%
5 changes: 5 additions & 0 deletions libs/numalogic-connectors/.coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[run]
branch = True
parallel = True
source = numalogic-connectors
omit = tests/*
10 changes: 10 additions & 0 deletions libs/numalogic-registry/.codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
coverage:
status:
project:
default:
target: auto
threshold: 3%
patch:
default:
target: auto
threshold: 20%
5 changes: 5 additions & 0 deletions libs/numalogic-registry/.coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[run]
branch = True
parallel = True
source = numalogic-registry
omit = tests/*

0 comments on commit 5a2bfc0

Please sign in to comment.