Skip to content

Commit 516a484

Browse files
committed
Bump versions, add CI
1 parent 570f1cc commit 516a484

File tree

5 files changed

+83
-9
lines changed

5 files changed

+83
-9
lines changed

.github/workflows/build.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Build
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags:
7+
- v*
8+
jobs:
9+
build_wheels:
10+
name: Build
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
- name: Install Poetry
15+
uses: snok/[email protected]
16+
- name: Build
17+
run: poetry build
18+
- uses: actions/upload-artifact@v3
19+
with:
20+
path: ./dist/*
21+
22+
upload_pypi:
23+
name: Upload to PyPI
24+
needs: [build_wheels]
25+
runs-on: ubuntu-latest
26+
environment: pypi
27+
permissions:
28+
id-token: write
29+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
30+
steps:
31+
- uses: actions/download-artifact@v3
32+
with:
33+
name: artifact
34+
path: dist
35+
36+
- uses: pypa/gh-action-pypi-publish@release/v1
37+
with:
38+
skip-existing: true

.github/workflows/ci.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
on:
2+
push:
3+
branches:
4+
- main
5+
pull_request:
6+
branches:
7+
- main
8+
9+
name: Run tests
10+
11+
jobs:
12+
tox_test:
13+
name: Tox tests
14+
steps:
15+
- uses: actions/checkout@v3
16+
- name: Run Tox tests
17+
id: test
18+
uses: fedora-python/tox-github-action@main
19+
with:
20+
tox_env: ${{ matrix.tox_env }}
21+
strategy:
22+
matrix:
23+
tox_env: [py39, py310, py311, py312]
24+
25+
# Use GitHub's Linux Docker host
26+
runs-on: ubuntu-latest
27+
pre_cmmit:
28+
name: Pre-commit
29+
runs-on: ubuntu-latest
30+
steps:
31+
- uses: actions/checkout@v3
32+
- uses: actions/setup-python@v3
33+
- uses: pre-commit/[email protected]

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
default_language_version:
2-
python: python3.10
2+
python: python3
33
repos:
44
- repo: https://github.com/charliermarsh/ruff-pre-commit
5-
rev: 'v0.0.272'
5+
rev: 'v0.0.283'
66
hooks:
77
- id: ruff
88
args: [ "--fix" ]
99
- repo: https://github.com/psf/black
10-
rev: "23.3.0"
10+
rev: "23.7.0"
1111
hooks:
1212
- id: black
1313
- repo: https://github.com/pre-commit/pre-commit-hooks

pyproject.toml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "pytest-unused-fixtures"
3-
version = "0.1.3"
3+
version = "0.1.4"
44
description = "A pytest plugin to list unused fixtures after a test run."
55
authors = ["Mikuláš Poul <[email protected]>"]
66
license = "MIT"
@@ -13,6 +13,7 @@ classifiers = [
1313
"Topic :: Software Development :: Testing",
1414
"Operating System :: OS Independent",
1515
"Programming Language :: Python :: 3",
16+
"Programming Language :: Python :: 3.9",
1617
"Programming Language :: Python :: 3.10",
1718
"Programming Language :: Python :: 3.11",
1819
"Programming Language :: Python :: 3.12",
@@ -30,8 +31,8 @@ python = "^3.9"
3031
pytest = "^7.3.2"
3132

3233
[tool.poetry.group.dev.dependencies]
33-
black = "^23.3.0"
34-
ruff = "^0.0.272"
34+
black = "^23.7.0"
35+
ruff = "^0.0.283"
3536
pytest-xdist = "^3.3.1"
3637

3738
[build-system]
@@ -40,13 +41,14 @@ build-backend = "poetry.core.masonry.api"
4041

4142
[tool.black]
4243
line-length = 120
43-
target_version = ['py310']
44+
target_version = ['py39', 'py310', 'py311', 'py312']
4445
include = '\.pyi?$'
4546
exclude = '''
4647
(
4748
/(
4849
\.git # exclude a few common directories in the
49-
| venv # root of the project
50+
| \.tox # root of the project
51+
| venv
5052
)/
5153
)
5254
'''

tox.ini

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
[tox]
22
envlist =
3-
py{39,310,311}
3+
py{39,310,311,312}
4+
isolated_build = true
45

56
[testenv]
67
deps = pytest

0 commit comments

Comments
 (0)