Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion tests/integration_tests_rust.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8790,7 +8790,15 @@ async fn lsps2_service_prunes_closed_channel_state() {

assert_eq!(list_lsps2_peer_states().await, vec![client_node.node_id().to_string()]);

client_node.close_channel(&client_user_channel_id, service_node.node_id()).unwrap();
// The client may still be persisting the monitor updates for the claim it just made, and LDK
// won't begin a cooperative shutdown while one is in flight.
tokio::time::timeout(Duration::from_secs(common::INTEROP_TIMEOUT_SECS), async {
while client_node.close_channel(&client_user_channel_id, service_node.node_id()).is_err() {
tokio::time::sleep(Duration::from_millis(100)).await;
}
})
.await
.expect("the client should be able to close the channel");
expect_event!(client_node, ChannelClosed);
expect_event!(service_node, ChannelClosed);

Expand Down
Loading