Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/TheAlgorithms/Python
/ test_sha1_hash
Function
test_sha1_hash
hashes/sha1.py:133–135 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
131
132
133
def
test_sha1_hash():
134
msg = b
"Test String"
135
assert SHA1Hash(msg).final_hash() == hashlib.sha1(msg).hexdigest()
# noqa: S324
136
137
138
def
main():
Callers
nothing calls this directly
Calls
2
SHA1Hash
Class · 0.85
final_hash
Method · 0.45
Tested by
no test coverage detected