MCPcopy Index your code
hub / github.com/apache/cassandra-python-driver / _verify_hash

Method _verify_hash

tests/unit/test_metadata.py:488–493  ·  view source on GitHub ↗
(self, fn)

Source from the content-addressed store, hash-verified

486 raise unittest.SkipTest('The cmurmur3 extension is not available')
487
488 def _verify_hash(self, fn):
489 self.assertEqual(fn(b'123'), -7468325962851647638)
490 self.assertEqual(fn(b'\x00\xff\x10\xfa\x99' * 10), 5837342703291459765)
491 self.assertEqual(fn(b'\xfe' * 8), -8927430733708461935)
492 self.assertEqual(fn(b'\x10' * 8), 1446172840243228796)
493 self.assertEqual(fn(str(cassandra.metadata.MAX_LONG).encode()), 7162290910810015547)
494
495
496class MD5TokensTest(unittest.TestCase):

Callers 2

test_murmur3_pythonMethod · 0.95
test_murmur3_cMethod · 0.95

Calls 1

encodeMethod · 0.45

Tested by

no test coverage detected