mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-04-09 04:54:16 +00:00
Apply typing to all of pre-commit-hooks
This commit is contained in:
parent
63cc3414e9
commit
030bfac7e4
54 changed files with 401 additions and 264 deletions
|
|
@ -2,8 +2,8 @@ import io
|
|||
|
||||
import pytest
|
||||
|
||||
from pre_commit_hooks.end_of_file_fixer import end_of_file_fixer
|
||||
from pre_commit_hooks.end_of_file_fixer import fix_file
|
||||
from pre_commit_hooks.end_of_file_fixer import main
|
||||
|
||||
|
||||
# Input, expected return value, expected output
|
||||
|
|
@ -35,7 +35,7 @@ def test_integration(input_s, expected_retval, output, tmpdir):
|
|||
path = tmpdir.join('file.txt')
|
||||
path.write_binary(input_s)
|
||||
|
||||
ret = end_of_file_fixer([path.strpath])
|
||||
ret = main([path.strpath])
|
||||
file_output = path.read_binary()
|
||||
|
||||
assert file_output == output
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue