add isort, os import to tests #7
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: Python package | |
on: [push] | |
jobs: | |
build: | |
env: | |
OPENAI_API_KEY : ${{ secrets.OPENAI_API_KEY }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python 3.11 | |
uses: actions/setup-python@v4 | |
with: | |
# Semantic version range syntax or exact version of a Python version | |
python-version: '3.11' | |
architecture: 'x64' | |
- name: Install Dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Linting | |
run: | | |
pip install ruff | |
ruff --format=github --target-version=py311 . | |
- name: Unit tests | |
run: | | |
pip install pytest | |
pytest unit_tests.py | |
- name: Integration tests | |
run: | | |
pip install pytest | |
pytest integration_tests.py |