Skip to content

Commit 7456b95

Browse files
committed
DROPME: Run test 100 times
1 parent 615c24a commit 7456b95

File tree

1 file changed

+38
-36
lines changed

1 file changed

+38
-36
lines changed

tests/integration_tests_vss.rs

Lines changed: 38 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -16,42 +16,44 @@ use ldk_node::Builder;
1616
#[tokio::test(flavor = "multi_thread", worker_threads = 1)]
1717
async fn channel_full_cycle_with_vss_store() {
1818
let (bitcoind, electrsd) = common::setup_bitcoind_and_electrsd();
19-
println!("== Node A ==");
20-
let esplora_url = format!("http://{}", electrsd.esplora_url.as_ref().unwrap());
21-
let config_a = common::random_config(true);
22-
let mut builder_a = Builder::from_config(config_a.node_config);
23-
builder_a.set_chain_source_esplora(esplora_url.clone(), None);
24-
let vss_base_url = std::env::var("TEST_VSS_BASE_URL").unwrap();
25-
let node_a = builder_a
26-
.build_with_vss_store_and_fixed_headers(
27-
vss_base_url.clone(),
28-
"node_1_store".to_string(),
29-
HashMap::new(),
30-
)
31-
.unwrap();
32-
node_a.start().unwrap();
19+
for i in 1..100 {
20+
println!("== Node A ==");
21+
let esplora_url = format!("http://{}", electrsd.esplora_url.as_ref().unwrap());
22+
let config_a = common::random_config(true);
23+
let mut builder_a = Builder::from_config(config_a.node_config);
24+
builder_a.set_chain_source_esplora(esplora_url.clone(), None);
25+
let vss_base_url = std::env::var("TEST_VSS_BASE_URL").unwrap();
26+
let node_a = builder_a
27+
.build_with_vss_store_and_fixed_headers(
28+
vss_base_url.clone(),
29+
format!("node_{}_1_store", i),
30+
HashMap::new(),
31+
)
32+
.unwrap();
33+
node_a.start().unwrap();
3334

34-
println!("\n== Node B ==");
35-
let config_b = common::random_config(true);
36-
let mut builder_b = Builder::from_config(config_b.node_config);
37-
builder_b.set_chain_source_esplora(esplora_url.clone(), None);
38-
let node_b = builder_b
39-
.build_with_vss_store_and_fixed_headers(
40-
vss_base_url,
41-
"node_2_store".to_string(),
42-
HashMap::new(),
43-
)
44-
.unwrap();
45-
node_b.start().unwrap();
35+
println!("\n== Node B ==");
36+
let config_b = common::random_config(true);
37+
let mut builder_b = Builder::from_config(config_b.node_config);
38+
builder_b.set_chain_source_esplora(esplora_url.clone(), None);
39+
let node_b = builder_b
40+
.build_with_vss_store_and_fixed_headers(
41+
vss_base_url,
42+
format!("node_{}_2_store", i),
43+
HashMap::new(),
44+
)
45+
.unwrap();
46+
node_b.start().unwrap();
4647

47-
common::do_channel_full_cycle(
48-
node_a,
49-
node_b,
50-
&bitcoind.client,
51-
&electrsd.client,
52-
false,
53-
true,
54-
false,
55-
)
56-
.await;
48+
common::do_channel_full_cycle(
49+
node_a,
50+
node_b,
51+
&bitcoind.client,
52+
&electrsd.client,
53+
false,
54+
true,
55+
false,
56+
)
57+
.await;
58+
}
5759
}

0 commit comments

Comments
 (0)