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

@ -33,7 +33,7 @@ def test_finds_breakpoint():
def test_returns_one_for_failing_file(tmpdir):
f_py = tmpdir.join('f.py')
f_py.write('def f():\n import pdb; pdb.set_trace()')
ret = main([f_py.strpath])
ret = main([str(f_py)])
assert ret == 1
@ -50,10 +50,10 @@ def test_syntaxerror_file():
def test_non_utf8_file(tmpdir):
f_py = tmpdir.join('f.py')
f_py.write_binary('# -*- coding: cp1252 -*-\nx = ""\n'.encode('cp1252'))
assert main((f_py.strpath,)) == 0
assert main((str(f_py),)) == 0
def test_py37_breakpoint(tmpdir):
f_py = tmpdir.join('f.py')
f_py.write('def f():\n breakpoint()\n')
assert main((f_py.strpath,)) == 1
assert main((str(f_py),)) == 1