[py-svn] r36819 - in py/dist/py/test/rsession: . testing
fijal at codespeak.net
fijal at codespeak.net
Tue Jan 16 16:57:02 CET 2007
Author: fijal
Date: Tue Jan 16 16:57:01 2007
New Revision: 36819
Modified:
py/dist/py/test/rsession/conftest.py
py/dist/py/test/rsession/testing/test_boxing.py
Log:
Remove dead code, turn on option, which should be on by default.
Modified: py/dist/py/test/rsession/conftest.py
==============================================================================
--- py/dist/py/test/rsession/conftest.py (original)
+++ py/dist/py/test/rsession/conftest.py Tue Jan 16 16:57:01 2007
@@ -1,21 +1,10 @@
import py
Option = py.test.Config.Option
-#defaultwait = 100.0
-
option = py.test.Config.addoptions("boxing test options",
- Option('', '--skip-kill-test', action='store_true', dest='skip_kill_test',
+ Option('', '--skip-kill-test', action='store_true', default=False,
+ dest='skip_kill_test',
help='skip a certain test that checks for os.kill results, this '
'should be used when kill() is not allowed for the current '
'user'),
)
-
-#option = py.test.Config.addoptions("distributed testing options",
-# Option('-D', '--disthosts',
-# action="store", dest="disthosts", default=None,
-# help="comma separated list of testhosts"),
-# Option('', '--waittime',
-# action="store", dest="waittime", default=defaultwait,
-# help="How long (in seconds) to wait for hanging nodes"
-# " (default=%s sec)" % defaultwait),
-# )
Modified: py/dist/py/test/rsession/testing/test_boxing.py
==============================================================================
--- py/dist/py/test/rsession/testing/test_boxing.py (original)
+++ py/dist/py/test/rsession/testing/test_boxing.py Tue Jan 16 16:57:01 2007
@@ -7,7 +7,7 @@
if sys.platform == 'win32':
py.test.skip("rsession is unsupported on Windows.")
-from py.__.test.rsession.box import Box, RealBox, ScreenBox
+from py.__.test.rsession.box import Box
from py.__.test.rsession.testing import example2
from py.__.test.rsession.conftest import option
@@ -28,7 +28,7 @@
assert b.retval == 1
def test_boxing_on_fds():
- b = RealBox(example2.boxf2)
+ b = Box(example2.boxf2)
b.run()
assert b.stdoutrepr == "someout"
assert b.stderrrepr == "someerr"
@@ -37,13 +37,13 @@
assert b.retval == 2
def test_boxing_signal():
- b = RealBox(example2.boxseg)
+ b = Box(example2.boxseg)
b.run()
assert b.signal == 11
assert b.retval is None
def test_boxing_huge_data():
- b = RealBox(example2.boxhuge)
+ b = Box(example2.boxhuge)
b.run()
assert b.stdoutrepr
assert b.exitstat == 0
@@ -53,7 +53,7 @@
def test_box_seq():
# we run many boxes with huge data, just one after another
for i in xrange(100):
- b = RealBox(example2.boxhuge)
+ b = Box(example2.boxhuge)
b.run()
assert b.stdoutrepr
assert b.exitstat == 0
@@ -62,13 +62,13 @@
def test_box_in_a_box():
def boxfun():
- b = RealBox(example2.boxf2)
+ b = Box(example2.boxf2)
b.run()
print b.stdoutrepr
print >>sys.stderr, b.stderrrepr
return b.retval
- b = RealBox(boxfun)
+ b = Box(boxfun)
b.run()
assert b.stdoutrepr == "someout\n"
assert b.stderrrepr == "someerr\n"
@@ -87,7 +87,7 @@
def box_fun():
time.sleep(10) # we don't want to last forever here
- b = RealBox(box_fun)
+ b = Box(box_fun)
par, pid = b.run(continuation=True)
os.kill(pid, 15)
par(pid)
More information about the pytest-commit
mailing list