(self)
| 1547 | |
| 1548 | @hashlib_helper.requires_hashdigest('sha256') |
| 1549 | def test_with_fallback(self): |
| 1550 | cache = getattr(hashlib, '__builtin_constructor_cache') |
| 1551 | try: |
| 1552 | cache['foo'] = hashlib.sha256 |
| 1553 | hexdigest = hmac.digest(b'key', b'message', 'foo').hex() |
| 1554 | expected = ('6e9ef29b75fffc5b7abae527d58fdadb' |
| 1555 | '2fe42e7219011976917343065f58ed4a') |
| 1556 | self.assertEqual(hexdigest, expected) |
| 1557 | finally: |
| 1558 | cache.pop('foo') |
| 1559 | |
| 1560 | @hashlib_helper.requires_openssl_hashdigest("md5") |
| 1561 | @bigmemtest(size=_4G + 5, memuse=2, dry_run=False) |
nothing calls this directly
no test coverage detected