mirror of
https://github.com/davidhalter/parso.git
synced 2026-01-03 01:53:47 +08:00
Add a test for the diff parser that xfails
This commit is contained in:
@@ -1669,3 +1669,31 @@ def test_yet_another_backslash(differ):
|
||||
differ.initialize(code1)
|
||||
differ.parse(code2, parsers=ANY, copies=ANY, expect_error_leaves=True)
|
||||
differ.parse(code1, parsers=ANY, copies=ANY)
|
||||
|
||||
|
||||
@pytest.mark.xfail
|
||||
def test_very_weird_indentation(differ):
|
||||
"""
|
||||
This test for now fails, because it's just hard to implement this, but it's
|
||||
also not really important.
|
||||
"""
|
||||
code1 = dedent('''\
|
||||
def f():
|
||||
x
|
||||
|
||||
def g():
|
||||
y
|
||||
z
|
||||
''')
|
||||
code2 = dedent('''\
|
||||
def f():
|
||||
x
|
||||
>\\
|
||||
def g():
|
||||
y
|
||||
x
|
||||
z
|
||||
''')
|
||||
|
||||
differ.initialize(code1)
|
||||
differ.parse(code2, parsers=1, copies=1, expect_error_leaves=True)
|
||||
|
||||
Reference in New Issue
Block a user