Avoid ref to a `Vec` when accessing custom onion TLVs
[rust-lightning] / lightning / src / ln / payment_tests.rs
index 72176760243bf25cae3dd3adfcb656a4be6417cd..26ecbb0bd249d116cf8e54f440145c60d1796bbd 100644 (file)
@@ -3781,7 +3781,7 @@ fn test_retry_custom_tlvs() {
                payment_hash, Some(payment_secret), events.pop().unwrap(), true, None).unwrap();
        match payment_claimable {
                Event::PaymentClaimable { onion_fields, .. } => {
-                       assert_eq!(onion_fields.unwrap().custom_tlvs(), &custom_tlvs);
+                       assert_eq!(&onion_fields.unwrap().custom_tlvs()[..], &custom_tlvs[..]);
                },
                _ => panic!("Unexpected event"),
        };