Merged in msabramo/pytest/remove_unused_import (pull request #146)

testing/test_capture.py: Remove unused stuff for PEP8 compliance
This commit is contained in:
holger krekel 2014-04-02 18:56:46 +02:00
commit 7d10a57514
1 changed files with 2 additions and 3 deletions

View File

@ -4,7 +4,6 @@ from __future__ import with_statement
import os
import sys
import py
import tempfile
import pytest
import contextlib
@ -858,7 +857,7 @@ class TestStdCapture:
def test_stdin_restored(self):
old = sys.stdin
with self.getcapture(in_=True) as cap:
with self.getcapture(in_=True):
newstdin = sys.stdin
assert newstdin != sys.stdin
assert sys.stdin is old
@ -867,7 +866,7 @@ class TestStdCapture:
print ("XXX this test may well hang instead of crashing")
print ("XXX which indicates an error in the underlying capturing")
print ("XXX mechanisms")
with self.getcapture() as cap:
with self.getcapture():
pytest.raises(IOError, "sys.stdin.read()")