Add simple tests to secure_hash
This commit is contained in:
parent
e9516e6308
commit
badc3a0929
1 changed files with 5 additions and 0 deletions
|
|
@ -42,6 +42,11 @@ proc `==`*(a, b: SecureHash): bool =
|
|||
SHA1Digest(a) == SHA1Digest(b)
|
||||
|
||||
|
||||
when isMainModule:
|
||||
let hash1 = secureHash("a93tgj0p34jagp9[agjp98ajrhp9aej]")
|
||||
doAssert hash1 == hash1
|
||||
doAssert parseSecureHash($hash1) == hash1
|
||||
|
||||
|
||||
# Copyright (c) 2011, Micael Hildenborg
|
||||
# All rights reserved.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue