pganti / micheles

Automatically exported from code.google.com/p/micheles
0 stars 0 forks source link

decorator: Test failures with Python 3.3 #9

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
$ PYTHONPATH="build/lib" python3.3 documentation3.py
**********************************************************************
File "documentation3.py", line 133, in __main__
Failed example:
    f1(0, 1)
Expected:
    Traceback (most recent call last):
       ...
    TypeError: f1() takes exactly 1 positional argument (2 given)
Got:
    Traceback (most recent call last):
      File "/usr/lib64/python3.3/doctest.py", line 1287, in __run
        compileflags, 1), test.globs)
      File "<doctest __main__[3]>", line 1, in <module>
        f1(0, 1)
      File "documentation3.py", line 908, in memoize
        cache[key] = result = func(*args, **kw)
    TypeError: f1() takes 1 positional argument but 2 were given
**********************************************************************
File "documentation3.py", line 1063, in __main__.test_kwonlyargs
Failed example:
    func('a', 'b', 'c', 'd', 'e', y='y', z='z', cat='dog')
Expected:
    calling func with args ('a', 'b', 'c', 'd', 'e'), {'y': 'y', 'z': 'z', 'cat': 'dog'}
    ('y', 'z')
Got:
    calling func with args ('a', 'b', 'c', 'd', 'e'), {'cat': 'dog', 'z': 'z', 'y': 'y'}
    ('y', 'z')
**********************************************************************
2 items had failures:
   1 of  63 in __main__
   1 of   2 in __main__.test_kwonlyargs
***Test Failed*** 2 failures.

Original issue reported on code.google.com by Arfrever...@gmail.com on 28 Sep 2012 at 11:41

GoogleCodeExporter commented 8 years ago
This bug was fixed in decorator >=3.4.0.

Original comment by Arfrever...@gmail.com on 20 Dec 2012 at 11:50

GoogleCodeExporter commented 8 years ago

Original comment by michele....@gmail.com on 16 Mar 2015 at 11:55