Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Aug 26, 2022
2 parents 35dc143 + 47c2cb3 commit db997d3
Show file tree
Hide file tree
Showing 7 changed files with 37 additions and 16 deletions.
1 change: 1 addition & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
omit =
# leading `*/` for pytest-dev/pytest-cov#456
*/.tox/*
*/pep517-build-env-*

[report]
show_missing = True
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ max_line_length = 88
[*.{yml,yaml}]
indent_style = space
indent_size = 2

[*.rst]
indent_style = space
33 changes: 24 additions & 9 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,36 +8,51 @@ jobs:
matrix:
python:
- 3.7
- 3.9
- "3.10"
- '3.10'
- '3.11'
platform:
- ubuntu-latest
- macos-latest
- windows-latest
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
python-version: ${{ matrix.python }}-dev
- name: Install tox
run: |
python -m pip install tox
- name: Run tests
run: tox

check: # This job does nothing and is only used for the branch protection
if: always()

needs:
- test

runs-on: ubuntu-latest

steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}

release:
needs: test
needs:
- check
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "3.10"
python-version: "3.11-dev"
- name: Install tox
run: |
python -m pip install tox
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
repos:
- repo: https://github.com/psf/black
rev: 22.1.0
rev: 22.6.0
hooks:
- id: black
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
),
dict(
pattern=r'PEP[- ](?P<pep_number>\d+)',
url='https://www.python.org/dev/peps/pep-{pep_number:0>4}/',
url='https://peps.python.org/pep-{pep_number:0>4}/',
),
],
)
Expand Down
8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ skip-string-normalization = true

[tool.setuptools_scm]

[pytest.enabler.black]
[tool.pytest-enabler.black]
addopts = "--black"

[pytest.enabler.mypy]
[tool.pytest-enabler.mypy]
addopts = "--mypy"

[pytest.enabler.flake8]
[tool.pytest-enabler.flake8]
addopts = "--flake8"

[pytest.enabler.cov]
[tool.pytest-enabler.cov]
addopts = "--cov"
4 changes: 3 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,16 @@ testing =
pytest >= 6
pytest-checkdocs >= 2.4
pytest-flake8
# workaround for tholo/pytest-flake8#87
flake8 < 5
pytest-black >= 0.3.7; \
# workaround for jaraco/skeleton#22
python_implementation != "PyPy"
pytest-cov
pytest-mypy >= 0.9.1; \
# workaround for jaraco/skeleton#22
python_implementation != "PyPy"
pytest-enabler >= 1.0.1
pytest-enabler >= 1.3

# local

Expand Down

0 comments on commit db997d3

Please sign in to comment.