Skip to content

Commit 5045fe0

Browse files
committed
Use nox instead of tox
1 parent 8cb86fd commit 5045fe0

3 files changed

Lines changed: 639 additions & 13 deletions

File tree

noxfile.py

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
import nox
2+
3+
nox.options.default_venv_backend = "uv"
4+
5+
python_versions = ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
6+
7+
8+
@nox.session(python=python_versions)
9+
def tests(session):
10+
session.install("--upgrade", "pip", "uv")
11+
session.install("html5lib==0.999999999", "django==1.10", "pyglet==2.0.dev23")
12+
session.install(".") # Assuming pip-check is in the current project
13+
14+
session.run("pip-check")
15+
session.run("pip-check", "--help")
16+
session.run(
17+
"pip-check",
18+
"--ascii",
19+
"--not-required",
20+
"--full-version",
21+
"--hide-unchanged",
22+
"--show-update",
23+
)
24+
session.run("pip-check", "--user")
25+
session.run("pip-check", "--local")
26+
27+
session.run("pip-check", "--cmd=uv pip")
28+
session.run("pip-check", "--cmd=uv pip", "--help")
29+
session.run(
30+
"pip-check", "--cmd=uv pip", "--ascii", "--full-version", "--hide-unchanged"
31+
)
32+
33+
34+
@nox.session
35+
def readme(session):
36+
session.install("markdown-it-py")
37+
session.run("markdown-it", "README.md", "/dev/null", external=True)

tox.ini

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,13 @@
55
toxworkdir=/tmp/tox/pip-check
66
envlist=
77
readme
8-
py{38,39,310,311,312,312}
8+
py{36,37,38,39,310,311,312,312,313}
99

1010

1111
[gh-actions]
1212
python =
13+
"3.6": py36
14+
"3.7": py37
1315
"3.8": py38
1416
"3.9": py39
1517
"3.10": py310
@@ -24,29 +26,25 @@ deps=
2426
pyglet==2.0.dev23
2527

2628
commands=
27-
# Always test against latest pip version
28-
pip install -U pip
29+
# Always test against latest pip and uv version
30+
pip install -U pip uv
31+
2932
pip-check
30-
pip-check --cmd=pip
3133
pip-check --help
3234
pip-check --ascii --not-required --full-version --hide-unchanged --show-update
3335
pip-check --user
3436
pip-check --local
3537

36-
pip-check
3738
pip-check --cmd="uv pip"
3839
pip-check --cmd="uv pip" --help
39-
pip-check --cmd="uv pip" --ascii --not-required --full-version --hide-unchanged --show-update
40-
pip-check --cmd="uv pip" --user
41-
pip-check --cmd="uv pip" --local
42-
40+
pip-check --cmd="uv pip" --ascii --full-version --hide-unchanged
4341

4442
[testenv:readme]
4543
skip_install = True
44+
basepython = python3.13
4645
deps =
47-
docutils
48-
Pygments
46+
markdown-it-py
4947
allowlist_externals =
50-
rst2html.py
48+
markdown-it
5149
commands =
52-
rst2html.py --report=info --halt=warning README.rst /dev/null
50+
markdown-it README.md /dev/null

0 commit comments

Comments
 (0)