[pypy-svn] pypy collections-module: Generalize the test.
arigo
commits-noreply at bitbucket.org
Wed Feb 16 11:03:57 CET 2011
Author: Armin Rigo <arigo at tunes.org>
Branch: collections-module
Changeset: r42018:b375e0d99e91
Date: 2011-02-16 10:58 +0100
http://bitbucket.org/pypy/pypy/changeset/b375e0d99e91/
Log: Generalize the test.
diff --git a/lib-python/modified-2.7.0/test/test_deque.py b/lib-python/modified-2.7.0/test/test_deque.py
--- a/lib-python/modified-2.7.0/test/test_deque.py
+++ b/lib-python/modified-2.7.0/test/test_deque.py
@@ -343,7 +343,10 @@
for match in (True, False):
d = deque(['ab'])
d.extend([MutateCmp(d, match), 'c'])
- self.assertRaises(IndexError, d.remove, 'c')
+ # On CPython we get IndexError: deque mutated during remove().
+ # Why is it an IndexError during remove() only???
+ # On PyPy it is a RuntimeError, as in the other operations.
+ self.assertRaises((IndexError, RuntimeError), d.remove, 'c')
self.assertEqual(d, deque())
def test_repr(self):
More information about the Pypy-commit
mailing list