MCPcopy Create free account
hub / github.com/subbarayudu-j/TheAlgorithms-Python / testMatchHashes

Method testMatchHashes

hashes/sha1.py:119–121  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

117 Test class for the SHA1Hash class. Inherits the TestCase class from unittest
118 """
119 def testMatchHashes(self):
120 msg = bytes('Test String', 'utf-8')
121 self.assertEqual(SHA1Hash(msg).final_hash(), hashlib.sha1(msg).hexdigest())
122
123
124def main():

Callers

nothing calls this directly

Calls 2

SHA1HashClass · 0.85
final_hashMethod · 0.80

Tested by

no test coverage detected