diff options
| author | Egor Tensin <egor@tensin.name> | 2026-10-14 22:50:19 +0500 |
|---|---|---|
| committer | Egor Tensin <egor@tensin.name> | 2026-10-14 22:50:19 +0500 |
| commit | 1113be584b46e7e037a2bc4ece9b3b938969ec75 (patch) | |
| tree | 937e7a6cf516db8c27c5373aae5ccfcbf9c8cd55 /README.md | |
| parent | main.sh: add proper command line parameters & usage info (diff) | |
| download | test-harness-0.3.0.tar.gz test-harness-0.3.0.zip | |
shuffle files around, add the top-level symlinkv0.3.0
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 33 |
1 files changed, 25 insertions, 8 deletions
@@ -8,22 +8,39 @@ Used in a bunch of projects of mine, for example: * [tag-release](https://github.com/egor-tensin/tag-release/tree/master/test) * [config-links](https://github.com/egor-tensin/config-links/tree/master/test) +Integration +----------- + +* Can be added as a submodule like so: + + > cd my/project/test + > git submodule add https://github.com/egor-tensin/test-harness.git runner + + * Run tests using the `harness` script: + + > ./test/runner/harness + + * This will pick up all test files in "project/test/". + +* Alternatively, check out this repo somewhere and use the `-d` parameter to +specify the path to the tests directory. + Usage ----- -Supposed to be added as a submodule like so: +* By default, all tests in the parent directory are run: - > cd my/project/test - > git submodule add https://github.com/egor-tensin/test-harness.git runner + ./test/runner/harness # Runs all tests in the test/ directory -This will add it as a submodule in `test/runner/` in your project's directory. +* You can filter tests to run using the `-f`/`--filter` parameter (uses +fnmatch(3)): -Run tests using the main.sh script: + ./test/runner/harness -f '*' # Runs all tests still + ./test/runner/harness -f '*label*' # Collects all test files containing "label" - > ./test/runner/main.sh +* Specify a directory to collect tests from using the `-d`/`--dir` parameter: -The script will discover all your tests in the parent directory, run them and -print a short summary. + ./harness -d path/to/tests/ API --- |
