add --pytest-test-first convention

This commit is contained in:
Anthony Sottile 2022-06-07 09:10:42 -07:00
parent 621f50e155
commit 412564fa95
4 changed files with 35 additions and 9 deletions

View file

@ -142,8 +142,10 @@ Replaces or checks mixed line ending.
- `no` - Checks if there is any mixed line ending without modifying any file.
#### `name-tests-test`
Assert that files in tests/ end in `_test.py`.
- Use `args: ['--django']` to match `test*.py` instead.
verifies that test files are named correctly.
- `--pytest` (the default): ensure tests match `.*_test\.py`
- `--pytest-test-first`: ensure tests match `test_.*\.py`
- `--django` / `--unittest`: ensure tests match `test.*\.py`
#### `no-commit-to-branch`
Protect specific branches from direct checkins.