Add failing test for incorrect zip321 amount parsing.

This commit is contained in:
Kris Nuttycombe 2024-03-05 21:44:51 -07:00
parent eaabc0f514
commit 6b4942f8eb
1 changed files with 5 additions and 0 deletions

View File

@ -1078,6 +1078,11 @@ mod tests {
"zcash:?amount.10000=1.23&address.10000=tmEZhbWHTpdKMw5it8YDspUXSMGQyFwovpU";
let i10r = TransactionRequest::from_uri(&TEST_NETWORK, invalid_10);
assert!(i10r.is_err());
// invalid: bad amount format
let invalid_11 = "zcash:?address=tmEZhbWHTpdKMw5it8YDspUXSMGQyFwovpU&amount=123.";
let i11r = TransactionRequest::from_uri(&TEST_NETWORK, invalid_11);
assert!(i11r.is_err());
}
proptest! {