InvenTree/.github/workflows/coverage.yaml

38 lines
933 B
YAML
Raw Normal View History

2021-03-31 02:06:22 +00:00
# Perform CI checks, and calculate code coverage
name: Code Coverage
2021-03-31 05:24:33 +00:00
on: ["push", "pull_request"]
2021-03-31 02:06:22 +00:00
jobs:
# Run tests on SQLite database
# These tests are used for code coverage analysis
coverage:
runs-on: ubuntu-latest
env:
2021-03-31 06:08:24 +00:00
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2021-03-31 02:06:22 +00:00
INVENTREE_DB_NAME: './test_db.sqlite'
INVENTREE_DB_ENGINE: sqlite3
steps:
- name: Checkout Code
uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Install Dependencies
run: |
sudo apt-get update
pip3 install invoke
invoke install
- name: Coverage Tests
run: |
invoke coverage
- name: Upload Coverage Report
2021-03-31 05:57:44 +00:00
run: coveralls
#uses: coverallsapp/github-action@master
#with:
# github-token: ${{ secrets.GITHUB_TOKEN }}