[svn r38104] fixing this so "py.test -s" passes on this as well

--HG--
branch : trunk
This commit is contained in:
hpk 2007-02-07 20:04:35 +01:00
parent 5b188f1167
commit 47aea3ca7b
1 changed files with 3 additions and 4 deletions

View File

@ -33,13 +33,12 @@ For calling functions you may use a shortcut:
:api:`py.io.StdCaptureFD`
---------------------------
If you also want to capture writes to the stdout/stdin
If you also want to capture writes to the stdout/stderr
filedescriptors you may invoke:
>>> import py, sys
>>> capture = py.io.StdCaptureFD()
>>> sys.stdout.write("hello")
>>> sys.stderr.write("world")
>>> out,err = capture.reset()
>>> out.strip() + err.strip() == "helloworld"
True
>>> err
'world'