Skip to content

Commit 58ab04c

Browse files
mpretty-cyrojagerman
authored andcommitted
Stopped reusing port numbers in case that's causing a test failure
1 parent 5b0c1ad commit 58ab04c

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tests/test_session_network.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1221,7 +1221,7 @@ TEST_CASE("Network", "[network][build_path_if_needed]") {
12211221
}
12221222

12231223
TEST_CASE("Network", "[network][establish_connection]") {
1224-
auto test_server = create_test_server(5000);
1224+
auto test_server = create_test_server(5100);
12251225
auto network = TestNetwork(std::nullopt, true, true, false);
12261226
std::promise<std::pair<connection_info, std::optional<std::string>>> prom;
12271227

@@ -1248,7 +1248,7 @@ TEST_CASE("Network", "[network][check_request_queue_timeouts]") {
12481248
// Test that it doesn't start checking for timeouts when the request doesn't have
12491249
// a build paths timeout
12501250
network.emplace(std::nullopt, true, true, false);
1251-
test_server.emplace(create_test_server(5001));
1251+
test_server.emplace(create_test_server(5201));
12521252
network->send_onion_request(
12531253
(*test_server)->node,
12541254
to_vector("{\"method\":\"info\",\"params\":{}}"),
@@ -1265,7 +1265,7 @@ TEST_CASE("Network", "[network][check_request_queue_timeouts]") {
12651265
// Test that it does start checking for timeouts when the request has a
12661266
// paths build timeout
12671267
network.emplace(std::nullopt, true, true, false);
1268-
test_server.emplace(create_test_server(5002));
1268+
test_server.emplace(create_test_server(5202));
12691269
network->ignore_calls_to("build_path");
12701270
network->send_onion_request(
12711271
(*test_server)->node,
@@ -1283,7 +1283,7 @@ TEST_CASE("Network", "[network][check_request_queue_timeouts]") {
12831283
// Test that it fails the request with a timeout if it has a build path timeout
12841284
// and the path build takes too long
12851285
network.emplace(std::nullopt, true, true, false);
1286-
test_server.emplace(create_test_server(5003));
1286+
test_server.emplace(create_test_server(5203));
12871287
network->ignore_calls_to("build_path");
12881288
network->send_onion_request(
12891289
(*test_server)->node,
@@ -1307,7 +1307,7 @@ TEST_CASE("Network", "[network][check_request_queue_timeouts]") {
13071307
}
13081308

13091309
TEST_CASE("Network", "[network][send_request]") {
1310-
auto test_server = create_test_server(5000);
1310+
auto test_server = create_test_server(5300);
13111311
auto network = TestNetwork(std::nullopt, true, true, false);
13121312
std::promise<Result> prom;
13131313

@@ -1360,7 +1360,7 @@ TEST_CASE("Network", "[network][send_request]") {
13601360
}
13611361

13621362
TEST_CASE("Network", "[network][send_onion_request]") {
1363-
auto test_server = create_test_server(5000);
1363+
auto test_server = create_test_server(5400);
13641364
auto network = TestNetwork(std::nullopt, true, true, false);
13651365
auto [test_path_servers, test_path] = network.create_test_path();
13661366
network.handle_onion_requests_as_plaintext = true;
@@ -1402,7 +1402,7 @@ TEST_CASE("Network", "[network][send_onion_request]") {
14021402
}
14031403

14041404
TEST_CASE("Network", "[network][c][network_send_onion_request]") {
1405-
auto test_server_cpp = create_test_server(5000);
1405+
auto test_server_cpp = create_test_server(5500);
14061406
auto test_network = std::make_unique<TestNetwork>(std::nullopt, true, true, false);
14071407
std::optional<std::pair<std::vector<std::shared_ptr<TestServer>>, onion_path>> test_path_data;
14081408
test_path_data.emplace(test_network->create_test_path());

0 commit comments

Comments
 (0)