Skip to content

Commit 1fd8565

Browse files
authored
Pass extra args to pytest through nox (#123)
1 parent 1499754 commit 1fd8565

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

docs/howto.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@ Running the tests is done using:
3131

3232
make test
3333

34+
The `nox` test session will pass pytest arguments through. For example,
35+
to run only the tests including "simple_search" in the test name, and only
36+
on Python 3.11:
37+
38+
nox -s test-3.11 -- -k simple_search
39+
3440
## Working on tantivy-py documentation
3541

3642
Please be aware that this documentation is structured using the [Diátaxis](https://diataxis.fr/) framework. In very simple terms, this framework will suggest the correct location for different kinds of documentation. Please make sure you gain a basic understanding of the goals of the framework before making large pull requests with new documentation.

noxfile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
def test(session):
66
session.install("-rrequirements-dev.txt")
77
session.install("-e", ".", "--no-build-isolation")
8-
session.run("pytest")
8+
session.run("pytest", *session.posargs)

0 commit comments

Comments
 (0)