mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-19 09:04:41 +04:00
Include hook id in output with --verbose. Closes #88.
This commit is contained in:
parent
edb04422b8
commit
cce97ccba9
4 changed files with 177 additions and 36 deletions
|
|
@ -330,3 +330,13 @@ def test_skip_hook(repo_with_passing_hook):
|
|||
)
|
||||
for msg in ('Bash hook', 'Skipped'):
|
||||
assert msg in printed
|
||||
|
||||
|
||||
def test_hook_id_not_in_non_verbose_output(repo_with_passing_hook):
|
||||
ret, printed = _do_run(repo_with_passing_hook, _get_opts(verbose=False))
|
||||
assert '[bash_hook]' not in printed
|
||||
|
||||
|
||||
def test_hook_id_in_verbose_output(repo_with_passing_hook):
|
||||
ret, printed = _do_run(repo_with_passing_hook, _get_opts(verbose=True))
|
||||
assert '[bash_hook] Bash hook' in printed
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue