Skip to content

Commit

Permalink
Add GitHub workflow to test with Python 3.7 - 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon committed Nov 15, 2023
1 parent d82b23c commit d6b5a88
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 3 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Test

on:
push:
# branches:
# - main
pull_request:
branches:
- main
schedule:
# Daily at 12:00 UTC
- cron: "0 12 * * *"

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Install Poetry
run: pipx install poetry

- name: Install dependencies
run: |
poetry env use ${{ matrix.python-version }}
poetry install
- name: Run tests
run: poetry run pytest
8 changes: 5 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ classifiers = ['Development Status :: 5 - Production/Stable',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Software Development :: Libraries :: Python Modules',
'Topic :: Utilities']
Expand All @@ -27,13 +29,13 @@ packages = [
]

[tool.poetry.dependencies]
python = "^3.7"
python = ">=3.7"

[tool.poetry.dev-dependencies]
flake8 = "^4.0.1"
mypy = "^0.942"
mypy = "^1.4"
pytest = "^7.1.2"
pytest-asyncio = "^0.18.3"
pytest-asyncio = "^0.21.1"
pytest-cov = "^3.0.0"
requests = "^2.26.0"
responses = "^0.20.0"
Expand Down

0 comments on commit d6b5a88

Please sign in to comment.