Use MAX_MONEY in serde regression test

We plan on enforcing MAX_MONEY in the amount types. In preparation use
MAX_MONEY in the serde regression test instead of the arbitrary, and too
large DEADBEEFCAFEBABE value.
This commit is contained in:
Tobin C. Harding 2025-01-24 09:17:24 +11:00
parent 67f3d498af
commit 08bb57e499
No known key found for this signature in database
GPG Key ID: 40BF9E4C269D6607
2 changed files with 2 additions and 4 deletions

View File

@ -109,10 +109,8 @@ fn serde_regression_txin() {
#[test]
fn serde_regression_txout() {
let txout = TxOut {
value: Amount::from_sat(0xDEADBEEFCAFEBABE),
script_pubkey: ScriptBuf::from(vec![0u8, 1u8, 2u8]),
};
let txout =
TxOut { value: Amount::MAX_MONEY, script_pubkey: ScriptBuf::from(vec![0u8, 1u8, 2u8]) };
let got = serialize(&txout).unwrap();
let want = include_bytes!("data/serde/txout_bincode") as &[_];
assert_eq!(got, want)