Author: Armin Rigo <ar...@tunes.org> Branch: cpyext-ext Changeset: r82647:1c037e8cb40d Date: 2016-03-01 21:20 +0100 http://bitbucket.org/pypy/pypy/changeset/1c037e8cb40d/
Log: Rewrite the test in a way independent of issue 2248 diff --git a/pypy/module/cpyext/test/test_typeobject.py b/pypy/module/cpyext/test/test_typeobject.py --- a/pypy/module/cpyext/test/test_typeobject.py +++ b/pypy/module/cpyext/test/test_typeobject.py @@ -489,8 +489,11 @@ class F(float): def __int__(self): return 666 - skip("XXX fix issue 2248 first") - assert module.nb_int(float, F(-12.3)) == -12 + # as long as issue 2248 is not fixed, 'expected' is 666 on pypy, + # but it should be -12. This test is not concerned about that, + # but only about getting the same answer with module.nb_int(). + expected = float.__int__(F(-12.3)) + assert module.nb_int(float, F(-12.3)) == expected def test_nb_float(self): module = self.import_extension('foo', [ _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit