(self, obj_text: str, expected_hash: str, expected_length: int)
| 7 | |
| 8 | class ObjectCacheTest(unittest.TestCase): |
| 9 | def check(self, obj_text: str, expected_hash: str, expected_length: int) -> None: |
| 10 | obj = assemble(obj_text) |
| 11 | th = ObjectCache(treehash) |
| 12 | self.assertEqual(th.get(obj).hex(), expected_hash) |
| 13 | sl = ObjectCache(serialized_length) |
| 14 | self.assertEqual(sl.get(obj), expected_length) |
| 15 | |
| 16 | def test_various(self) -> None: |
| 17 | self.check( |
no test coverage detected