jsatt / mock

Automatically exported from code.google.com/p/mock
BSD 2-Clause "Simplified" License
0 stars 0 forks source link

Testsuite fails under py3.4 #225

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. set system python to py3.4 or just use py3.4
2. run the testsuite
3. observe

What is the expected output? What do you see instead?
Pass all.

----------------------------------------------------------------------
Ran 278 tests in 0.517s

FAILED (SKIP=9, errors=32)
 * ERROR: dev-python/mock-1.0.1-r1::gentoo failed (test phase):
 *   Tests fail with python3.4

What version of the product are you using? On what operating system?
-1.0.1
gentoo linux

Please provide any additional information below.

.EE.............................EEEEEEEEEE.EE/usr/lib64/python3.4/unittest/case.
py:522: RuntimeWarning: TestResult has no addExpectedFailure method, reporting 
as passes
  RuntimeWarning)
.E..EEE.SSE.EESEEEE...........................S.....SS..........................
....S........................SS......E.E.E.E.....E..............................
..................E.............E........................................

============================================================
Here's the first
============================================================

ERROR: test_create_autopsec (tests.testcallable.TestCallable)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/mnt/gen2/TmpDir/portage/dev-python/mock-1.0.1-r1/work/mock-1.0.1/tests/testcallable.py", line 143, in test_create_autopsec
    mock = create_autospec(X)
  File "/mnt/gen2/TmpDir/portage/dev-python/mock-1.0.1-r1/work/mock-1.0.1-python3_4/lib/mock.py", line 2193, in create_autospec
    _check_signature(spec, mock, is_type, instance)
  File "/mnt/gen2/TmpDir/portage/dev-python/mock-1.0.1-r1/work/mock-1.0.1-python3_4/lib/mock.py", line 213, in _check_signature
    _copy_func_details(func, checksig)
  File "/mnt/gen2/TmpDir/portage/dev-python/mock-1.0.1-r1/work/mock-1.0.1-python3_4/lib/mock.py", line 221, in _copy_func_details
    funcopy.__module__ = func.__module__
AttributeError: 'wrapper_descriptor' object has no attribute '__module__'

The last 3 lines, 2193 213 221, of mock.py are cited in ALL 32 errors.
They pass fine under py3.3
Clearly this is a py3.4 issue.

Do you require a full build.log?  
Also, do you test under py3.4?

Original issue reported on code.google.com by del...@iinet.com.au on 8 Apr 2014 at 7:27