Allow typing.Self
as a hint-type.
#145
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions | |
name: tests | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.9", "3.10", "3.11", "3.12"] | |
os: [ubuntu-latest, windows-latest, macos-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 1 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: pip | |
cache-dependency-path: requirements-tests.txt | |
- name: Install dependencies | |
run: pip install -r requirements-tests.txt | |
- name: Test with pytest | |
run: pytest | |
- name: Check formatting with black | |
uses: psf/black@stable | |
with: | |
src: "./structured" | |
- name: Check formatting with isort | |
run: isort structured | |
- name: Lint with flake8 | |
run: | | |
# Use the flake8-pyproject entry point to pull in config from | |
# pyproject.toml | |
flake8p structured |