mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
A workaround for the missing buffer() builtin in jython.
This closes patch "[ #490850 ] Jython and test_StringIO".
This commit is contained in:
parent
82b230732f
commit
793ead5696
1 changed files with 6 additions and 0 deletions
|
@ -74,6 +74,12 @@ class TestStringIO(TestGenericStringIO):
|
|||
class TestcStringIO(TestGenericStringIO):
|
||||
MODULE = cStringIO
|
||||
|
||||
import sys
|
||||
if sys.platform.startswith('java'):
|
||||
# Jython doesn't have a buffer object, so we just do a useless
|
||||
# fake of the buffer tests.
|
||||
buffer = str
|
||||
|
||||
class TestBufferStringIO(TestStringIO):
|
||||
constructor = buffer
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue