Make xdist work even if looponfail or boxed are disabled

Fix #32
This commit is contained in:
Bruno Oliveira
2015-12-12 10:26:31 -02:00
parent 8ba24ef627
commit c58d22f279
4 changed files with 27 additions and 9 deletions

View File

@@ -535,6 +535,19 @@ def test_tmpdir_disabled(testdir):
result.stdout.fnmatch_lines("*1 passed*")
@pytest.mark.parametrize('plugin', ['xdist.looponfail', 'xdist.boxed'])
def test_sub_plugins_disabled(testdir, plugin):
"""Test that xdist doesn't break if we disable any of its sub-plugins. (#32)
"""
p1 = testdir.makepyfile("""
def test_ok():
pass
""")
result = testdir.runpytest(p1, "-n1", '-p', 'no:%s' % plugin)
assert result.ret == 0
result.stdout.fnmatch_lines("*1 passed*")
class TestNodeFailure:
def test_load_single(self, testdir):
f = testdir.makepyfile("""