add xfailing test for double test id failure

This commit is contained in:
Ronny Pfannschmidt 2015-11-24 21:24:15 +01:00
parent 9ea7826427
commit 04e9ae75c8
1 changed files with 11 additions and 0 deletions

View File

@ -659,3 +659,14 @@ def test_random_report_log_xdist(testdir):
failed.append(case_node['name']) failed.append(case_node['name'])
assert failed == ['test_x[22]'] assert failed == ['test_x[22]']
@pytest.mark.xfail(reason='duplicate test ids kill us')
def test_runs_twice(testdir):
f = testdir.makepyfile('''
def test_pass():
pass
''')
result = testdir.runpytest(f, f, '--junitxml', testdir.tmpdir.join("test.xml"))
assert 'INTERNALERROR' not in result.stdout