Skip to content

Commit 3145168

Browse files
committed
Only run aggressive test_node_counter_consistency in tests
`test_node_counter_consistency` can make gossip operations *really* slow. This makes it a pretty bad idea in a general node just running in debug mode. It also makes our `lightning-rapid-gossip-sync` real-world test painfully slow. Thus, here, we make `test_node_counter_consistency` only actually run in the `lightning`-crate tests, rather than always with `debug_assertions`.
1 parent 830ffa0 commit 3145168

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lightning/src/routing/gossip.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1786,7 +1786,7 @@ where
17861786
}
17871787

17881788
fn test_node_counter_consistency(&self) {
1789-
#[cfg(debug_assertions)]
1789+
#[cfg(test)]
17901790
{
17911791
let channels = self.channels.read().unwrap();
17921792
let nodes = self.nodes.read().unwrap();

0 commit comments

Comments
 (0)