From 741cffc04ca6ac638f858c8d16065a26e26a20d5 Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Sun, 19 Jan 2020 00:13:13 -0500 Subject: [PATCH] Demonstrate mutating functions which are not fully test-covered --- lightning/src/ln/channel.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lightning/src/ln/channel.rs b/lightning/src/ln/channel.rs index 262342d41..65fb99197 100644 --- a/lightning/src/ln/channel.rs +++ b/lightning/src/ln/channel.rs @@ -2360,6 +2360,7 @@ impl Channel { } } + #[cfg_attr(all(test, feature = "mutation_testing"), mutate)] /// Removes any uncommitted HTLCs, to be used on peer disconnection, including any pending /// HTLCs that we intended to add but haven't as we were waiting on a remote revoke. /// Returns the set of PendingHTLCStatuses from remote uncommitted HTLCs (which we're @@ -2446,6 +2447,7 @@ impl Channel { self.channel_state |= ChannelState::MonitorUpdateFailed as u32; } + #[cfg_attr(all(test, feature = "mutation_testing"), mutate)] /// Indicates that the latest ChannelMonitor update has been committed by the client /// successfully and we should restore normal operation. Returns messages which should be sent /// to the remote side. -- 2.39.5