Enable hash checking in serial tests

This commit is contained in:
Dan Doel 2023-08-28 09:47:54 -04:00
parent ce3e06c217
commit 9126105c94

View File

@ -101,14 +101,14 @@ serial.runTestCase name =
handle
p@(f, i) = loadSelfContained name sfile
o = fromUtf8 (readFile ofile)
-- h = readFile hfile
h = readFile hfile
if toBase32 (crypto.hash Sha3_512 p) === h
then pass (name ++ " hash matches")
else fail name "hash mismatch"
if f i === o
then pass name
-- todo: check hashes
-- if toBase32 (crypto.hash Sha3_512 p) == h
-- then pass name
-- else fail name "hash mismatch"
then pass (name ++ "value matches")
else fail name "output mismatch"
with cases
{ x } -> x