|
@@ -70,7 +70,7 @@ goodRoundTrip = do
|
|
|
let algo = chunkedChaChaPoly1305 32 testKey
|
|
|
(enc, fails1) = encrypt algo testNonce 0 testString
|
|
|
(dec, fails2) = decrypt algo testNonce 0 enc
|
|
|
- case sequence fails1 >> sequence fails2 of
|
|
|
+ case sequence_ fails1 >> sequence fails2 of
|
|
|
CryptoPassed _ -> if dec == testString
|
|
|
then return . Finished $ Pass
|
|
|
else return . Finished . Fail $ "Text differs: " ++ C8.unpack dec
|
|
@@ -85,7 +85,7 @@ authError = do
|
|
|
Just (t, tt) -> do
|
|
|
let enc' = LBS.cons (t+1) tt
|
|
|
(dec, fails2) = decrypt algo testNonce 0 enc'
|
|
|
- case sequence fails1 >> sequence fails2 of
|
|
|
+ case sequence_ fails1 >> sequence fails2 of
|
|
|
CryptoFailed CryptoError_MacKeyInvalid -> return . Finished $ Pass
|
|
|
CryptoFailed e -> return . Finished . Fail $ "Crypto failed: " ++ show e
|
|
|
CryptoPassed _ -> return . Finished . Fail $ "Got decrypted text: " ++ C8.unpack dec
|