Skip to content

Add python

Add python #6

name: Run Python Unit Tests
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
run-pytests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ "3.11" ]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Set up virtual environment and install dependencies
run: |
cd python_bindings
python -m venv venv
source venv/bin/activate
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install maturin
- name: Build the codelist package
run: |
source python_bindings/venv/bin/activate
maturin develop
- name: Run tests
run: python -m unittest discover