summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornoah <noah@656d521f-e311-0410-88e0-e7920216d269>2002-10-22 02:28:50 +0000
committernoah <noah@656d521f-e311-0410-88e0-e7920216d269>2002-10-22 02:28:50 +0000
commit930eda316b824671b4c83318484f9c9a16922e68 (patch)
tree76e676de1bcda3feff7f30f80ad1ac7005585525
parentb5a469710b388585409e0b05cf69ff492cec4cac (diff)
downloadpexpect-930eda316b824671b4c83318484f9c9a16922e68.tar.gz
Still can't get the Darwin MacOS X problem.
git-svn-id: http://pexpect.svn.sourceforge.net/svnroot/pexpect/trunk@111 656d521f-e311-0410-88e0-e7920216d269
-rw-r--r--pexpect/pexpect.py10
-rwxr-xr-xpexpect/tests/test_constructor.py1
2 files changed, 5 insertions, 6 deletions
diff --git a/pexpect/pexpect.py b/pexpect/pexpect.py
index f934335..1e75191 100644
--- a/pexpect/pexpect.py
+++ b/pexpect/pexpect.py
@@ -381,11 +381,11 @@ class spawn:
# For this case, I test isalive() before doing any reading.
# If isalive() is false, then I pretend that this is the same as EOF.
if not self.isalive():
- r, w, e = select.select([self.child_fd], [], [], 0)
- if not r:
- self.flag_eof = 1
- raise EOF ('End Of File (EOF) in read(). Braindead platform.')
-
+ r, w, e = select.select([self.child_fd], [], [], 0)
+ if not r:
+ self.flag_eof = 1
+ raise EOF ('End Of File (EOF) in read(). Braindead platform.')
+
r, w, e = select.select([self.child_fd], [], [], timeout)
if not r:
raise TIMEOUT('Timeout exceeded in read().')
diff --git a/pexpect/tests/test_constructor.py b/pexpect/tests/test_constructor.py
index ddac622..fea0efd 100755
--- a/pexpect/tests/test_constructor.py
+++ b/pexpect/tests/test_constructor.py
@@ -3,7 +3,6 @@ import pexpect
import unittest
class TestCaseConstructor(unittest.TestCase):
- #def runTest (self):
def test_constructor (self):
"""This tests that the constructor will work and give