summaryrefslogtreecommitdiffstats
path: root/Lib/unittest/test/testmock
diff options
context:
space:
mode:
authorKushal Das <kushaldas@gmail.com>2014-04-15 19:52:52 (GMT)
committerKushal Das <kushaldas@gmail.com>2014-04-15 19:52:52 (GMT)
commit5d1f6c3b15435749002e2f08e8d88812a328c0e5 (patch)
tree86bf08ce7f90fea2c2d0cd00ba5270d44b130f4d /Lib/unittest/test/testmock
parenta3b99a07e6d75d707b5c8a0cadb6b059638da650 (diff)
parent484f8a875b986690f9d8aec2089368b70184e009 (diff)
downloadcpython-5d1f6c3b15435749002e2f08e8d88812a328c0e5.zip
cpython-5d1f6c3b15435749002e2f08e8d88812a328c0e5.tar.gz
cpython-5d1f6c3b15435749002e2f08e8d88812a328c0e5.tar.bz2
Merge
Diffstat (limited to 'Lib/unittest/test/testmock')
-rw-r--r--Lib/unittest/test/testmock/testmock.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/unittest/test/testmock/testmock.py b/Lib/unittest/test/testmock/testmock.py
index 70f19d3..23675b9 100644
--- a/Lib/unittest/test/testmock/testmock.py
+++ b/Lib/unittest/test/testmock/testmock.py
@@ -1182,6 +1182,10 @@ class MockTest(unittest.TestCase):
func.mock_calls, [call(1, 2), call(3, 4)]
)
+ #Issue21222
+ def test_create_autospec_with_name(self):
+ m = mock.create_autospec(object(), name='sweet_func')
+ self.assertIn('sweet_func', repr(m))
def test_mock_add_spec(self):
class _One(object):