Skip to content

Commit

Permalink
chore: Update Python version to 3.11 in run-pytest.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
codeperfectplus committed Jun 1, 2024
1 parent b81601f commit e4959bb
Showing 1 changed file with 17 additions and 21 deletions.
38 changes: 17 additions & 21 deletions .github/workflows/run-pytest.yaml
Original file line number Diff line number Diff line change
@@ -1,35 +1,31 @@
name: Run Pytest
name: Python package

on: [push, pull_request]
on: [push]

jobs:
build:

runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]

steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
- uses: actions/checkout@v4
- name: Set up Python
# This is the version of the action for setting up Python, not the Python version.
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
# Semantic version range syntax or exact version of a Python version
python-version: '3.11'
# Optional - x64 or x86 architecture, defaults to x64
architecture: 'x64'
# You can test your matrix by printing the current Python version
- name: Display Python version
run: python -c "import sys; print(sys.version)"

- name: Install dependencies
run: |
sudo apt-get update
sudo apt install libespeak-dev
sudo apt-get install python-dateutil
python -m pip install --upgrade pip
pip install flake8 pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=200 --statistics --ignore=E501,E402
pip install -r requirements.txt
- name: Test with pytest
run: |
pytest
pip install pytest pytest-cov
pytest tests --doctest-modules --junitxml=junit/test-results.xml --cov=com --cov-report=xml --cov-report=html

0 comments on commit e4959bb

Please sign in to comment.