[pypy-commit] pypy py3.6: we don't have this restriction of cpython

cfbolz pypy.commits at gmail.com
Tue Sep 17 05:43:43 EDT 2019


Author: Carl Friedrich Bolz-Tereick <cfbolz at gmx.de>
Branch: py3.6
Changeset: r97508:3ead6447613b
Date: 2019-09-17 11:42 +0200
http://bitbucket.org/pypy/pypy/changeset/3ead6447613b/

Log:	we don't have this restriction of cpython

diff --git a/lib-python/3/unittest/test/testmock/testhelpers.py b/lib-python/3/unittest/test/testmock/testhelpers.py
--- a/lib-python/3/unittest/test/testmock/testhelpers.py
+++ b/lib-python/3/unittest/test/testmock/testhelpers.py
@@ -2,6 +2,8 @@
 import types
 import unittest
 
+from test.support import cpython_only
+
 from unittest.mock import (
     call, _Call, create_autospec, MagicMock,
     Mock, ANY, _CallList, patch, PropertyMock
@@ -873,7 +875,7 @@
         # plain data descriptor
         check_data_descriptor(foo.desc)
 
-
+    @cpython_only # PyPy can easily extract a spec from a builtin function
     def test_autospec_on_bound_builtin_function(self):
         meth = types.MethodType(time.ctime, time.time())
         self.assertIsInstance(meth(), str)


More information about the pypy-commit mailing list