Skip to content

Commit

Permalink
fixes: error on github workflows.
Browse files Browse the repository at this point in the history
  • Loading branch information
yothgewalt committed Aug 8, 2024
1 parent 807bcb7 commit 9534152
Showing 1 changed file with 27 additions and 28 deletions.
55 changes: 27 additions & 28 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
@@ -1,35 +1,34 @@
name: Python Tests

on:
push:
branches:
- main
pull_request:
branches:
- main
on: [push]

jobs:
test:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]

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

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest junitparser
- name: Run tests with pytest
run: |
pytest --junitxml=report.xml
- name: Parse test results
run: python test_results.py

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

- name: Display Python version
run: python -c "import sys; print(sys.version)"

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run tests with pytest and export report of testing
run: |
pytest --junitxml=report.xml
- name: Parse test results
run: python test_results.py

if: ${{ always() }}

0 comments on commit 9534152

Please sign in to comment.