diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 04b7714..8fc7a28 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -18,7 +18,7 @@ jobs: matrix: os: [ubuntu-latest] # https://github.com/actions/python-versions/blob/main/versions-manifest.json - python-version: [3.8, 3.9, "3.10", "3.11", "3.12", "3.13-dev"] + python-version: [3.8, 3.9, "3.10", "3.11", "3.12", "3.13"] # "3.14-dev" include: # other OS version necessary - os: macos-latest @@ -51,10 +51,12 @@ jobs: # package setup - uses: actions/checkout@v4 + - name: Install dependencies + run: python -m pip install -e ".[dev]" + # tests - name: Lint with flake8 run: | - python -m pip install --upgrade flake8 # 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 @@ -62,21 +64,15 @@ jobs: - name: Code format with black run: | - python -m pip install --upgrade black black --check --diff courlan - - name: Install dependencies - run: python -m pip install -e "." - - name: Type checking with mypy run: | - python -m pip install --upgrade mypy types-urllib3 mypy -p courlan - name: Test with pytest run: | - python -m pip install --upgrade pytest pytest-cov - pytest --cov=./ --cov-report=xml + python -m pytest --cov=./ --cov-report=xml # coverage - name: Upload coverage to Codecov diff --git a/MANIFEST.in b/MANIFEST.in index 0be3773..e6cd28d 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,4 +1,4 @@ -include CONTRIBUTING.md HISTORY.md README.rst LICENSE pytest.ini +include CONTRIBUTING.md HISTORY.md README.rst LICENSE include courlan_harns-march.jpg include courlan/py.typed diff --git a/pyproject.toml b/pyproject.toml index b31cdf4..ec19904 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,7 +76,12 @@ courlan = "courlan.cli:main" [project.optional-dependencies] dev = [ "black", + "flake8", "mypy", "pytest", "pytest-cov", + "types-urllib3", ] + +[tool.pytest.ini_options] +testpaths = "tests/*test*.py" diff --git a/pytest.ini b/pytest.ini deleted file mode 100644 index 1d96487..0000000 --- a/pytest.ini +++ /dev/null @@ -1,2 +0,0 @@ -[pytest] -python_files = tests/*test*.py