]> git.ipfire.org Git - thirdparty/httpx.git/commitdiff
Allow passing additional pytest args to scripts/test (#1710)
authorFlorimond Manca <florimond.manca@gmail.com>
Thu, 24 Jun 2021 10:15:59 +0000 (12:15 +0200)
committerGitHub <noreply@github.com>
Thu, 24 Jun 2021 10:15:59 +0000 (11:15 +0100)
docs/contributing.md
scripts/test

index e1a953dc97e76c0cb138e14e1bd1f0681822c047..74472575c3b4dd8f22823ed5578b9f560e975a90 100644 (file)
@@ -71,10 +71,12 @@ $ scripts/test
     The test suite spawns testing servers on ports **8000** and **8001**.
     Make sure these are not in use, so the tests can run properly.
 
-You can run a single test script like this:
+Any additional arguments will be passed to `pytest`. See the [pytest documentation](https://docs.pytest.org/en/latest/how-to/usage.html) for more information.
+
+For example, to run a single test script:
 
 ```shell
-$ scripts/test -- tests/test_multipart.py
+$ scripts/test tests/test_multipart.py
 ```
 
 To run the code auto-formatting:
index f7f32ad12bb044c3c2992089f52c9ccd0a3dfbbe..d778a544d2a45588e1f13c6e9a2e9a58fbb7b50f 100755 (executable)
@@ -11,7 +11,7 @@ if [ -z $GITHUB_ACTIONS ]; then
     scripts/check
 fi
 
-${PREFIX}coverage run -m pytest
+${PREFIX}coverage run -m pytest "$@"
 
 if [ -z $GITHUB_ACTIONS ]; then
     scripts/coverage