[py-svn] pytest-xdist commit f9015ac57647: fix looponfailing issue to always run against the newest version of the source
commits-noreply at bitbucket.org
commits-noreply at bitbucket.org
Mon May 17 17:29:44 CEST 2010
# HG changeset patch -- Bitbucket.org
# Project pytest-xdist
# URL http://bitbucket.org/hpk42/pytest-xdist/overview
# User holger krekel <holger at merlinux.eu>
# Date 1274110354 -7200
# Node ID f9015ac5764770f42c6d6b69db9d8e91fc93ea76
# Parent 56d8e5280be224a0ad3220a9deed55334710bd23
fix looponfailing issue to always run against the newest version of the source
--- a/testing/test_remote.py
+++ b/testing/test_remote.py
@@ -61,7 +61,6 @@ class TestLooponFailing:
""")
session = LooponfailingSession(modcol.config)
loopstate = LoopState()
- session.remotecontrol.setup()
session.loop_once(loopstate)
assert len(loopstate.colitems) == 1
@@ -83,7 +82,6 @@ class TestLooponFailing:
""")
session = LooponfailingSession(modcol.config)
loopstate = LoopState()
- session.remotecontrol.setup()
loopstate.colitems = []
session.loop_once(loopstate)
assert len(loopstate.colitems) == 1
@@ -110,7 +108,6 @@ class TestLooponFailing:
""")
session = LooponfailingSession(modcol.config)
loopstate = LoopState()
- session.remotecontrol.setup()
loopstate.colitems = []
session.loop_once(loopstate)
assert len(loopstate.colitems) == 2
--- a/xdist/remote.py
+++ b/xdist/remote.py
@@ -24,7 +24,6 @@ class LooponfailingSession(Session):
def main(self, initialitems):
try:
self.loopstate = loopstate = LoopState([])
- self.remotecontrol.setup()
while 1:
self.loop_once(loopstate)
if not loopstate.colitems and loopstate.wasfailing:
@@ -34,10 +33,10 @@ class LooponfailingSession(Session):
print
def loop_once(self, loopstate):
+ self.remotecontrol.setup()
colitems = loopstate.colitems
loopstate.wasfailing = colitems and len(colitems)
loopstate.colitems = self.remotecontrol.runsession(colitems or ())
- self.remotecontrol.setup()
class LoopState:
def __init__(self, colitems=None):
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,9 @@
+1.3
+-------------------------
+
+- fix --looponfailing - it would not actually run against the fully changed
+ source tree when initial conftest files load application state.
+
1.2
-------------------------
More information about the pytest-commit
mailing list