Author: Antonio Cuni <[email protected]>
Branch: py3k
Changeset: r53882:ed773b252600
Date: 2012-03-22 09:54 +0100
http://bitbucket.org/pypy/pypy/changeset/ed773b252600/

Log:    we no longer have buffers, but we have memoryview instead

diff --git a/pypy/module/struct/test/test_struct.py 
b/pypy/module/struct/test/test_struct.py
--- a/pypy/module/struct/test/test_struct.py
+++ b/pypy/module/struct/test/test_struct.py
@@ -379,11 +379,11 @@
         assert self.struct.unpack("uuu", data) == ('X', 'Y', 'Z')
 
 
-    def test_unpack_buffer(self):
+    def test_unpack_memoryview(self):
         """
-        Buffer objects can be passed to struct.unpack().
+        memoryview objects can be passed to struct.unpack().
         """
-        b = buffer(self.struct.pack("ii", 62, 12))
+        b = memoryview(self.struct.pack("ii", 62, 12))
         assert self.struct.unpack("ii", b) == (62, 12)
         raises(self.struct.error, self.struct.unpack, "i", b)
 
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to