From ed93778e004a2c6c2160f54d7362f14c5797d9c6 Mon Sep 17 00:00:00 2001 From: Andrew Leech Date: Tue, 10 Mar 2020 15:14:35 +1100 Subject: py/objstringio: Expose tell() on StringIO and BytesIO objects. To match file objects. Fixes issue #5581. --- tests/basics/io_stringio1.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tests/basics/io_stringio1.py') diff --git a/tests/basics/io_stringio1.py b/tests/basics/io_stringio1.py index 9f7c1e44ef..41089f22d5 100644 --- a/tests/basics/io_stringio1.py +++ b/tests/basics/io_stringio1.py @@ -33,6 +33,11 @@ a = io.StringIO() a.write("foo") print(a.read()) +a = io.StringIO() +print(a.tell()) +a.write("foo") +print(a.tell()) + a = io.StringIO() a.close() for f in [a.read, a.getvalue, lambda:a.write("")]: -- cgit v1.2.3