name: Python package

on: [push, pull_request]

jobs:
  build:

    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: [3.6, 3.7, 3.8]

    steps:
    - 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: |
        sudo apt-get -y install plantuml
        python -m pip install --upgrade pip
        pip install pytest
        pip install --upgrade setuptools
        pip install pytest pre-commit
        pip install -c requirements.txt -e .[tests,sphinx,svgsupport,aafiguresupport,mathsupport,rawhtmlsupport]
    - name: Lint
      run: |
        pre-commit run --all-files --show-diff-on-failure
      if: matrix.python-version == '3.8'
    - name: Test with pytest
      continue-on-error: true
      run: |
        pytest -v
    - name: Archive test output
      uses: actions/upload-artifact@v2
      with:
        name: failed-tests
        path: rst2pdf/tests/output
        retention-days: 8

name: Python package

on: [push, pull_request]

jobs:
  build:

    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: [3.6, 3.7, 3.8, 3.9]

    steps:
    - 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: |
        sudo apt-get -y install plantuml
        python -m pip install --upgrade pip
        pip install pytest
        pip install --upgrade setuptools
        pip install pytest pre-commit
        pip install -c requirements.txt -e .[tests,sphinx,svgsupport,aafiguresupport,mathsupport,rawhtmlsupport]
    - name: Lint
      run: |
        pre-commit run --all-files --show-diff-on-failure
      if: matrix.python-version == '3.8'
    - name: Test with pytest
      continue-on-error: true
      run: |
        pytest -v
    - name: Archive test output
      uses: actions/upload-artifact@v2
      with:
        name: failed-tests
        path: rst2pdf/tests/output
        retention-days: 8

Add Python 3.9 to the CI test matrix
Add Python 3.9 to the CI test matrix
