[pypy-svn] r45201 - pypy/dist/pypy/annotation/test
arigo at codespeak.net
arigo at codespeak.net
Thu Jul 19 13:24:14 CEST 2007
Author: arigo
Date: Thu Jul 19 13:24:13 2007
New Revision: 45201
Modified:
pypy/dist/pypy/annotation/test/test_annrpython.py
Log:
A skipped test showing a problem with _annenforceargs_.
Modified: pypy/dist/pypy/annotation/test/test_annrpython.py
==============================================================================
--- pypy/dist/pypy/annotation/test/test_annrpython.py (original)
+++ pypy/dist/pypy/annotation/test/test_annrpython.py Thu Jul 19 13:24:13 2007
@@ -2455,6 +2455,17 @@
assert not s.nonneg
py.test.raises(Exception, a.build_types, fun, [s_nonneg, int])
+ def test_sig_bug(self):
+ py.test.skip("_annenforceargs_ does not work for default arguments")
+ def g(x, y=5):
+ return y == 5
+ g._annenforceargs_ = (int, int)
+ def fun(x):
+ return g(x)
+ a = self.RPythonAnnotator()
+ s = a.build_types(fun, [int])
+ assert not s.is_constant()
+
def test_slots_check(self):
class Base(object):
__slots__ = 'x'
More information about the Pypy-commit
mailing list