noxfile.py
This file
Path
noxfile.py
40 lines · 1.1 KiB · Python
Last changed by
Move all tooling configuration to setup.cfg (#204)Humberto Rochabefore adoptione51b212
History of this fileTake it
Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 1–11why, one step back1import nox23source_files = ("httpx", "tests", "setup.py", "noxfile.py")456@nox.session(reuse_venv=True)7def lint(session):8 session.install("autoflake", "black", "flake8", "isort", "seed-isort-config")910 session.run("autoflake", "--in-place", "--recursive", *source_files)11 session.run("seed-isort-config", "--application-directories=httpx")Move all tooling configuration to setup.cfg (#204)Humberto Rochabefore adoptione51b212
line 12why, one step back12 session.run("isort", "--project=httpx", "--recursive", "--apply", *source_files)Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 13–19why, one step back13 session.run("black", "--target-version=py36", *source_files)1415 check(session)161718@nox.session(reuse_venv=True)19def check(session):Add flake8-comprehensions to nox check task (#200)Can Sarıgölbefore adoption1b82d63
lines 20–22why, one step back20 session.install(21 "black", "flake8", "flake8-bugbear", "flake8-comprehensions", "mypy"22 )Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 23–24why, one step back2324 session.run("black", "--check", "--target-version=py36", *source_files)Move all tooling configuration to setup.cfg (#204)Humberto Rochabefore adoptione51b212
lines 25–26why, one step back25 session.run("flake8", *source_files)26 session.run("mypy", "httpx")Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 27–39why, one step back272829@nox.session(reuse_venv=True)30def docs(session):31 session.install("mkdocs", "mkdocs-material")3233 session.run("mkdocs", "build")343536@nox.session(python=["3.6", "3.7", "3.8"])37def test(session):38 session.install("-r", "test-requirements.txt")39Move all tooling configuration to setup.cfg (#204)Humberto Rochabefore adoptione51b212
line 40why, one step back40 session.run("python", "-m", "pytest")