MCPcopy Index your code
hub / github.com/python/cpython / test_copy

Method test_copy

Lib/test/test_functools.py:345–352  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

343 self.assertEqual(signature(f_copy), signature(f))
344
345 def test_copy(self):
346 f = self.partial(signature, ['asdf'], bar=[True])
347 f.attr = []
348 f_copy = copy.copy(f)
349 self.assertEqual(signature(f_copy), signature(f))
350 self.assertIs(f_copy.attr, f.attr)
351 self.assertIs(f_copy.args, f.args)
352 self.assertIs(f_copy.keywords, f.keywords)
353
354 def test_deepcopy(self):
355 f = self.partial(signature, ['asdf'], bar=[True])

Callers

nothing calls this directly

Calls 5

partialMethod · 0.80
signatureFunction · 0.70
copyMethod · 0.45
assertEqualMethod · 0.45
assertIsMethod · 0.45

Tested by

no test coverage detected