MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_copy

Method test_copy

Lib/test/test_hmac.py:1124–1131  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1122 self.assertEqual(h.block_size, self.block_size)
1123
1124 def test_copy(self):
1125 # Test a generic copy() and the attributes it exposes.
1126 # See https://github.com/python/cpython/issues/142451.
1127 h1 = self.hmac_new(b"my secret key", digestmod=self.digestname)
1128 h2 = h1.copy()
1129 self.assertEqual(h1.name, h2.name)
1130 self.assertEqual(h1.digest_size, h2.digest_size)
1131 self.assertEqual(h1.block_size, h2.block_size)
1132
1133 def test_repr(self):
1134 # HMAC object representation may differ across implementations

Callers

nothing calls this directly

Calls 3

hmac_newMethod · 0.45
copyMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected