Skip to content

Commit

Permalink
Properly check that result is an error (#64)
Browse files Browse the repository at this point in the history
  • Loading branch information
khernyo authored and yoshuawuyts committed Apr 23, 2019
1 parent 0719a5a commit b209cc1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/crypto/key_pair.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ fn can_verify_messages() {
let from = b"hello";
let sig = sign(&keypair.public, &keypair.secret, from);
verify(&keypair.public, from, Some(&sig)).unwrap();
verify(&keypair.public, b"oops", Some(&sig)).is_err();
verify(&keypair.public, b"oops", Some(&sig)).unwrap_err();
}

0 comments on commit b209cc1

Please sign in to comment.