name: CI

on:
  push:
    branches:
      - main
  pull_request:
    branches:
      - main

jobs:
  test:
    runs-on: ubuntu-latest

    strategy:
      matrix:
        python-version: ['3.11']

    steps:
    - name: Checkout repository
      uses: actions/checkout@v2

    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v2
      with:
        python-version: ${{ matrix.python-version }}

    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install -r requirements.txt
        pip install pyyaml
    - name: Run tests
      env:
        PYTHONPATH: ${{ github.workspace }}/src
        TESTING: true
      run: |
        python -m unittest discover -s tests -p '*.py'

