Don't use LocalPath.strpath

This commit is contained in:
Max Rozentsveyg 2020-05-20 12:07:45 -04:00
parent e37b2795ff
commit f35bfed79e
23 changed files with 69 additions and 69 deletions

View file

@ -42,7 +42,7 @@ TESTS = (
def test_rewrite(input_s, output, expected_retval, tmpdir):
path = tmpdir.join('file.py')
path.write(input_s)
retval = main([path.strpath])
retval = main([str(path)])
assert path.read() == output
assert retval == expected_retval
@ -50,5 +50,5 @@ def test_rewrite(input_s, output, expected_retval, tmpdir):
def test_rewrite_crlf(tmpdir):
f = tmpdir.join('f.py')
f.write_binary(b'"foo"\r\n"bar"\r\n')
assert main((f.strpath,))
assert main((str(f),))
assert f.read_binary() == b"'foo'\r\n'bar'\r\n"