mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-04-15 01:51:46 +04:00
Don't crash when an executable is not found
This commit is contained in:
parent
da7e85c851
commit
5a6b6e81e9
5 changed files with 37 additions and 13 deletions
|
|
@ -108,7 +108,7 @@ def test_find_executable_path_ext(in_tmpdir):
|
|||
def test_normexe_does_not_exist():
|
||||
with pytest.raises(OSError) as excinfo:
|
||||
parse_shebang.normexe('i-dont-exist-lol')
|
||||
assert excinfo.value.args == ('Executable i-dont-exist-lol not found',)
|
||||
assert excinfo.value.args == ('Executable `i-dont-exist-lol` not found',)
|
||||
|
||||
|
||||
def test_normexe_already_full_path():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue