Skip to content

Commit

Permalink
Document options of invoke test command
Browse files Browse the repository at this point in the history
  • Loading branch information
axelboc committed Mar 7, 2024
1 parent 4be8eb6 commit 508cbdd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,15 @@ Tests are handled with [pytest](https://docs.pytest.org/en/stable/index.html). T
Once `h5grove` is installed in editable mode, run the tests with

```
invoke test
invoke test [--options]
```

Available options (cf. `invoke --help test`):

- `-c`, `--cov-lines`: display line numbers in coverage report
- `-k [keyword]`, `--keyword [keyword]`: filter tests by keyword
- `-v`, `--verbose`: enable verbose test output

### Benchmarks

Benchmarks of different formats (`json`, `.npy`) and web server frameworks (`flask`, `tornado`) are run as part of the tests. Those benchmarks are based on [pytest-benchmark](https://pytest-benchmark.readthedocs.io/en/latest/).
Expand Down
2 changes: 1 addition & 1 deletion tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def lint(c):
mypy(c)


@task
@task(optional=["verbose", "keyword", "cov-lines"])
def test(c, verbose=False, keyword="", cov_lines=False):
"""Test without benchmark"""
c.run(
Expand Down

0 comments on commit 508cbdd

Please sign in to comment.