[pypy-commit] pypy py3k: fix test to pass on CPython

rlamy pypy.commits at gmail.com
Wed Oct 5 12:05:18 EDT 2016


Author: Ronan Lamy <ronan.lamy at gmail.com>
Branch: py3k
Changeset: r87597:907be97a82d0
Date: 2016-10-05 17:02 +0100
http://bitbucket.org/pypy/pypy/changeset/907be97a82d0/

Log:	fix test to pass on CPython

diff --git a/pypy/module/cpyext/test/test_memoryobject.py b/pypy/module/cpyext/test/test_memoryobject.py
--- a/pypy/module/cpyext/test/test_memoryobject.py
+++ b/pypy/module/cpyext/test/test_memoryobject.py
@@ -60,9 +60,7 @@
                  return PyMemoryView_FromBuffer(&info);
                  """)])
         exc = raises(ValueError, module.fillinfo_NULL)
-        expected = ("cannot make memory view from a buffer with a NULL data "
-                    "pointer")
-        assert str(exc.value) == expected
+        assert 'NULL' in str(exc.value)
 
     @pytest.mark.skipif(True, reason='write a test for this')
     def test_get_base_and_get_buffer(self, space, api):


More information about the pypy-commit mailing list