From: Matt Corallo <649246+TheBlueMatt@users.noreply.github.com> Date: Thu, 1 Apr 2021 21:38:03 +0000 (+0000) Subject: Merge pull request #860 from TheBlueMatt/2021-03-bench-sends X-Git-Tag: v0.0.14~40 X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=df732f4a6decc355626554d8bc0c7c8bccbe59e7;hp=8a9f0b8cedaf63a921456a27dea9ecba88f3ebcd;p=rust-lightning Merge pull request #860 from TheBlueMatt/2021-03-bench-sends Add a simple send-funds benchmark in channelmanager --- diff --git a/fuzz/src/chanmon_consistency.rs b/fuzz/src/chanmon_consistency.rs index 7c5875ac1..e7cd99008 100644 --- a/fuzz/src/chanmon_consistency.rs +++ b/fuzz/src/chanmon_consistency.rs @@ -234,7 +234,7 @@ fn check_api_err(api_err: APIError) { _ if err.starts_with("Cannot send value that would put our balance under counterparty-announced channel reserve value") => {}, _ if err.starts_with("Cannot send value that would overdraw remaining funds.") => {}, _ if err.starts_with("Cannot send value that would not leave enough to pay for fees.") => {}, - _ => panic!(err), + _ => panic!("{}", err), } }, APIError::MonitorUpdateFailed => { diff --git a/fuzz/src/router.rs b/fuzz/src/router.rs index e93618ca7..fb720c991 100644 --- a/fuzz/src/router.rs +++ b/fuzz/src/router.rs @@ -130,7 +130,7 @@ pub fn do_test(data: &[u8], out: Out) { msgs::DecodeError::InvalidValue => return, msgs::DecodeError::BadLengthDescriptor => return, msgs::DecodeError::ShortRead => panic!("We picked the length..."), - msgs::DecodeError::Io(e) => panic!(format!("{:?}", e)), + msgs::DecodeError::Io(e) => panic!("{:?}", e), } } }}