mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-04-08 04:34:16 +00:00
Don't use LocalPath.strpath
This commit is contained in:
parent
e37b2795ff
commit
f35bfed79e
23 changed files with 69 additions and 69 deletions
|
|
@ -4,10 +4,10 @@ from pre_commit_hooks import check_byte_order_marker
|
|||
def test_failure(tmpdir):
|
||||
f = tmpdir.join('f.txt')
|
||||
f.write_text('ohai', encoding='utf-8-sig')
|
||||
assert check_byte_order_marker.main((f.strpath,)) == 1
|
||||
assert check_byte_order_marker.main((str(f),)) == 1
|
||||
|
||||
|
||||
def test_success(tmpdir):
|
||||
f = tmpdir.join('f.txt')
|
||||
f.write_text('ohai', encoding='utf-8')
|
||||
assert check_byte_order_marker.main((f.strpath,)) == 0
|
||||
assert check_byte_order_marker.main((str(f),)) == 0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue