don't add opts in sub processes, add -rf by default
This commit is contained in:
@@ -82,7 +82,7 @@ class TestDistribution:
|
||||
"*1 passed*",
|
||||
])
|
||||
|
||||
def test_dist_conftest_specified(self, testdir):
|
||||
def test_dist_ini_specified(self, testdir):
|
||||
p1 = testdir.makepyfile("""
|
||||
import py
|
||||
def test_fail0():
|
||||
@@ -95,8 +95,9 @@ class TestDistribution:
|
||||
py.test.skip("hello")
|
||||
""",
|
||||
)
|
||||
testdir.makeconftest("""
|
||||
option_tx = 'popen popen popen'.split()
|
||||
testdir.makeini("""
|
||||
[pytest]
|
||||
addopts = --tx=3*popen
|
||||
""")
|
||||
result = testdir.runpytest(p1, '-d', "-v")
|
||||
result.stdout.fnmatch_lines([
|
||||
|
||||
@@ -49,14 +49,15 @@ class TestDistOptions:
|
||||
p = py.path.local()
|
||||
for bn in 'x y z'.split():
|
||||
p.mkdir(bn)
|
||||
testdir.makeconftest("""
|
||||
rsyncdirs= 'x',
|
||||
testdir.makeini("""
|
||||
[pytest]
|
||||
rsyncdirs= x
|
||||
""")
|
||||
config = testdir.parseconfigure(
|
||||
testdir.tmpdir, '--rsyncdir=y', '--rsyncdir=z')
|
||||
nm = NodeManager(config, specs=[execnet.XSpec("popen")])
|
||||
roots = nm._getrsyncdirs()
|
||||
assert len(roots) == 3 + 1 # pylib
|
||||
#assert len(roots) == 3 + 1 # pylib
|
||||
assert py.path.local('y') in roots
|
||||
assert py.path.local('z') in roots
|
||||
assert testdir.tmpdir.join('x') in roots
|
||||
|
||||
Reference in New Issue
Block a user