(self)
| 1291 | self.assertEqual(type(h1._outer), type(h2._outer)) |
| 1292 | |
| 1293 | def test_realcopy(self): |
| 1294 | # Testing if the copy method created a real copy. |
| 1295 | h1 = hmac.HMAC.__new__(hmac.HMAC) |
| 1296 | h1._init_old(b"key", b"msg", digestmod="sha256") |
| 1297 | h2 = h1.copy() |
| 1298 | # Using id() in case somebody has overridden __eq__/__ne__. |
| 1299 | self.assertNotEqual(id(h1), id(h2)) |
| 1300 | self.assertNotEqual(id(h1._inner), id(h2._inner)) |
| 1301 | self.assertNotEqual(id(h1._outer), id(h2._outer)) |
| 1302 | |
| 1303 | def test_equality(self): |
| 1304 | # Testing if the copy has the same digests. |
nothing calls this directly
no test coverage detected