feat(testing): add testing for ontology-builder #16
Workflow file for this run
This file contains 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: Push Tests | |
on: | |
pull_request: | |
branches: | |
- "*" | |
push: | |
branches: | |
- "main" | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
permissions: | |
id-token: write | |
contents: read | |
jobs: | |
lint: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 2 | |
- uses: actions/setup-python@v5 | |
- name: lint checks | |
uses: pre-commit/action@v3.0.0 | |
unit-test-ontonolgy-builder: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.pull_request.head.ref }} | |
- name: Set up Python | |
uses: actions/setup-python@v1 | |
with: | |
python-version: 3.11 | |
- name: Python cache | |
uses: actions/cache@v1 | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements*.txt') }} | |
restore-keys: | | |
${{ runner.os }}-pip- | |
- name: Install dependencies | |
run: | | |
pip install -r tools/ontology-builder/requirements.txt | |
pip install -r tools/ontology-builder/requirements-dev.txt | |
- name: Ontology Dry Run Unit Tests | |
run: | | |
cd tools/ontology-builder && make unit-tests |