mirror of
https://github.com/senju1337/senju.git
synced 2025-12-24 07:39:29 +00:00
add(feat/OPS-31): code coverage for ci
This commit is contained in:
parent
ff50d4f5bb
commit
49baf0001b
2 changed files with 31 additions and 0 deletions
31
.github/workflows/ci.yml
vendored
Normal file
31
.github/workflows/ci.yml
vendored
Normal file
|
|
@ -0,0 +1,31 @@
|
||||||
|
name: CI # Name of the workflow
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- devel # Runs only when a pull request targets the 'devel' branch
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
test: # Defines a job called "test"
|
||||||
|
runs-on: ubuntu-latest # The job runs on the latest Ubuntu runner
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout Repository
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.10'
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: pip install -r requirements.txt
|
||||||
|
|
||||||
|
- name: Run tests with coverage
|
||||||
|
run: pytest --cov=senju --cov-report=xml
|
||||||
|
|
||||||
|
- name: Upload coverage to Codecov
|
||||||
|
uses: codecov/codecov-action@v3
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.CODECOV_TOKEN }}
|
||||||
|
file: ./coverage.xml
|
||||||
0
senju/__init__.py
Normal file
0
senju/__init__.py
Normal file
Loading…
Add table
Add a link
Reference in a new issue