[pypy-svn] r77366 - pypy/branch/fast-forward/pypy/module/select/test
afa at codespeak.net
afa at codespeak.net
Sat Sep 25 13:47:52 CEST 2010
Author: afa
Date: Sat Sep 25 13:47:51 2010
New Revision: 77366
Modified:
pypy/branch/fast-forward/pypy/module/select/test/test_select.py
Log:
A 2.7 socket "relies on reference counting to close
the underlying socket object".
I don't like this, but the call to gc.collect() is needed for
the test to pass with the -A option on pypy-c.
I suspect there will be a lot more of theses issues.
Modified: pypy/branch/fast-forward/pypy/module/select/test/test_select.py
==============================================================================
--- pypy/branch/fast-forward/pypy/module/select/test/test_select.py (original)
+++ pypy/branch/fast-forward/pypy/module/select/test/test_select.py Sat Sep 25 13:47:51 2010
@@ -112,6 +112,7 @@
# more data is available
if sys.platform != 'win32':
writeend.close()
+ import gc; gc.collect()
assert 1 <= total_out <= 512
total_in = 0
while True:
@@ -140,6 +141,7 @@
readend, writeend = self.getpair()
try:
readend.close()
+ import gc; gc.collect()
iwtd, owtd, ewtd = select.select([writeend], [], [], 0)
assert iwtd == [writeend]
assert owtd == ewtd == []
More information about the Pypy-commit
mailing list