[pypy-commit] pypy py3.5: Fix for -A

arigo pypy.commits at gmail.com
Thu Nov 3 14:30:46 EDT 2016


Author: Armin Rigo <arigo at tunes.org>
Branch: py3.5
Changeset: r88132:cb0741c5a10c
Date: 2016-11-03 19:22 +0100
http://bitbucket.org/pypy/pypy/changeset/cb0741c5a10c/

Log:	Fix for -A

diff --git a/pypy/objspace/std/test/test_bytesobject.py b/pypy/objspace/std/test/test_bytesobject.py
--- a/pypy/objspace/std/test/test_bytesobject.py
+++ b/pypy/objspace/std/test/test_bytesobject.py
@@ -140,8 +140,9 @@
     def test_format_wrongtype(self):
         for int_format in '%d', '%o', '%x':
             exc_info = raises(TypeError, int_format.__mod__, '123')
-            expected = int_format + ' format: a number is required, not str'
-            assert str(exc_info.value) == expected
+            expected1 = int_format + ' format: a number is required, not str'
+            expected2 = int_format + ' format: an integer is required, not str'
+            assert str(exc_info.value) in (expected1, expected2)
         raises(TypeError, "None % 'abc'") # __rmod__
 
     def test_split(self):


More information about the pypy-commit mailing list