noxfile.py
This file
Path
noxfile.py
54 lines · 1.4 KiB · Python
Last changed by
Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
History of this fileTake it
Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 1–2why, one step back1import nox2Stop running nox on first error (#286)Jt Miclatbefore adoption33032df
line 3why, one step back3nox.options.stop_on_first_error = TrueMake nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 4why, one step back4nox.options.reuse_existing_virtualenvs = TrueStop running nox on first error (#286)Jt Miclatbefore adoption33032df
line 5why, one step back5Add tool for profiling (#364)Florimond Mancabefore adoptione1da6b9
line 6why, one step back6source_files = ("httpx", "tools", "tests", "setup.py", "noxfile.py")Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 7–8why, one step back78Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 9why, one step back9@nox.sessionUse nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
line 10why, one step back10def lint(session):Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
lines 11–13why, one step back11 session.install(12 "--upgrade", "autoflake", "black", "flake8", "isort", "seed-isort-config"13 )Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 14–16why, one step back1415 session.run("autoflake", "--in-place", "--recursive", *source_files)16 session.run("seed-isort-config", "--application-directories=httpx")Move all tooling configuration to setup.cfg (#204)Humberto Rochabefore adoptione51b212
line 17why, one step back17 session.run("isort", "--project=httpx", "--recursive", "--apply", *source_files)Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 18–22why, one step back18 session.run("black", "--target-version=py36", *source_files)1920 check(session)2122Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 23why, one step back23@nox.sessionUse nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
line 24why, one step back24def check(session):Add flake8-comprehensions to nox check task (#200)Can Sarıgölbefore adoption1b82d63
line 25why, one step back25 session.install(Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 26why, one step back26 "--upgrade",Add flake8-pie plugin (#419)Stephen Brown IIbefore adoptiondb3e3a0
lines 27–33why, one step back27 "black",28 "flake8",29 "flake8-bugbear",30 "flake8-comprehensions",31 "flake8-pie",32 "isort",33 "mypy",Add flake8-comprehensions to nox check task (#200)Can Sarıgölbefore adoption1b82d63
line 34why, one step back34 )Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
line 35why, one step back35Add --diff flag to Black for easier debugging (#219)euri10before adoptione64fcad
line 36why, one step back36 session.run("black", "--check", "--diff", "--target-version=py36", *source_files)Move all tooling configuration to setup.cfg (#204)Humberto Rochabefore adoptione51b212
lines 37–38why, one step back37 session.run("flake8", *source_files)38 session.run("mypy", "httpx")Run isort in the nox check session (#379)Jamie Hewlandbefore adoption276ee73
lines 39–41why, one step back39 session.run(40 "isort", "--check", "--diff", "--project=httpx", "--recursive", *source_files41 )Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 42–43why, one step back4243Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 44why, one step back44@nox.sessionUse nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
line 45why, one step back45def docs(session):Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 46why, one step back46 session.install("--upgrade", "mkdocs", "mkdocs-material", "pymdown-extensions")Use nox for automation and CI (#128)Seth Michael Larsonbefore adoption80dc3e2
lines 47–52why, one step back4748 session.run("mkdocs", "build")495051@nox.session(python=["3.6", "3.7", "3.8"])52def test(session):Make nox always reuse virtualenvs by default (#460)Florimond Mancabefore adoption7361d60
line 53why, one step back53 session.install("--upgrade", "-r", "test-requirements.txt")Allow per file running of tests (#287)Jt Miclatbefore adoption1f4b8dd
line 54why, one step back54 session.run("python", "-m", "pytest", *session.posargs)