(self)
| 1255 | self.assertNotEqual(id(h1._outer), id(h2._outer)) |
| 1256 | |
| 1257 | def test_equality(self): |
| 1258 | # Testing if the copy has the same digests. |
| 1259 | h1 = hmac.HMAC(b"key", digestmod="sha256") |
| 1260 | h1.update(b"some random text") |
| 1261 | h2 = h1.copy() |
| 1262 | self.assertEqual(h1.digest(), h2.digest()) |
| 1263 | self.assertEqual(h1.hexdigest(), h2.hexdigest()) |
| 1264 | |
| 1265 | def test_equality_new(self): |
| 1266 | # Testing if the copy has the same digests with hmac.new(). |