Add knowledge graph builder #9
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: pytest and coverage | |
permissions: | |
contents: write | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install . | |
pip install .[test] | |
- name: Pytest | |
run: coverage run -m pytest -v -s | |
- name: Test coverage | |
run: coverage report -m | |
- name: Creating coverage folder | |
run: | | |
mkdir -p coverage | |
- name: Generate coverage Bagdge | |
uses: tj-actions/coverage-badge-py@v1.8 | |
with: | |
output: coverage/coverage.svg | |
- name: Publish coverage report to coverage-badge branch | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
branch: coverage-badge | |
folder: coverage |