Skip to content

Commit

Permalink
#150: Add nox 'tests' session
Browse files Browse the repository at this point in the history
- This will run the discovered unit tests in multiple versions of Python (unless nox is specified with -p [version_num] which is probably what I'll do for the majority of the time, just useful to test multi-version compatability)
  • Loading branch information
MRichards99 committed Nov 9, 2020
1 parent 96b3728 commit 29f8111
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,10 @@ def safety(session):
external=True,
)
session.run("safety", "check", f"--file={requirements.name}", "--full-report")


@nox.session(python=["3.6", "3.7", "3.8"], reuse_venv=True)
def tests(session):
args = session.posargs
session.run("poetry", "install", external=True)
session.run("pytest", *args)

0 comments on commit 29f8111

Please sign in to comment.