-
Notifications
You must be signed in to change notification settings - Fork 1
/
noxfile.py
29 lines (24 loc) · 895 Bytes
/
noxfile.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
"""All the process that can be run using nox.
The nox run are build in isolated environment that will be stored in .nox. to force the venv update, remove the .nox/xxx folder.
"""
import nox
@nox.session(reuse_venv=True, venv_backend="uv")
def test(session):
"""Run all the test using the environment variable of the running machine."""
session.install(
"pytest",
"nox",
"copier",
"jinja2-time",
"pre-commit",
"pytest-copie>=0.1.6", # force use HEAD in vcs-ref
"pyyaml",
"pytest-regressions",
)
test_files = session.posargs or ["tests"]
session.run("pytest", *test_files)
@nox.session(reuse_venv=True, venv_backend="uv")
def docs(session):
"""Build the documentation."""
session.install("-r", "docs/requirements.txt")
session.run("sphinx-build", "-v", "-b", "html", "docs", f"docs/_build/html")