Skip to content

Merge test workflow #11

Merge test workflow

Merge test workflow #11

name: Run Pytest before merging to main
on:
pull_request:
branches:
- main
jobs:
test:
runs-on: [ self-hosted, dind ]
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.10'
- name: Set up Python environment
run: |
python -m venv venv
source venv/bin/activate
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Check Python and Pip paths
run: |
python -c "import sys; print(sys.path)"
pip --version
which pip
pip list
- name: Run pytest
run: |
source venv/bin/activate
pytest -m tests