diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..724751c --- /dev/null +++ b/.github/workflows/test.yml @@ -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 diff --git a/pyproject.toml b/pyproject.toml index e0a6180..bf20f17 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -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'] @@ -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"