Skip to content

Commit

Permalink
fix: Fix XNet end-to-end tests (#2985)
Browse files Browse the repository at this point in the history
Encode the arguments to the start method as the newly defined StartArgs
struct instead of a tuple.
  • Loading branch information
alin-at-dfinity authored Dec 5, 2024
1 parent df6e86c commit 1b65617
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions rs/tests/message_routing/common/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use ic_system_test_driver::driver::test_env::TestEnv;
use ic_system_test_driver::driver::test_env_api::get_dependency_path;
use slog::info;
use std::{convert::TryFrom, env};
use xnet_test::StartArgs;

/// Concurrently calls `start` on all canisters in `canisters` with the
/// given parameters.
Expand All @@ -29,10 +30,14 @@ pub async fn start_all_canisters(
.enumerate()
.flat_map(|(x, v)| v.iter().enumerate().map(move |(y, v)| (x, y, v)))
{
let input = (&topology, canister_to_subnet_rate, payload_size_bytes);
let input = StartArgs {
network_topology: topology.clone(),
canister_to_subnet_rate,
payload_size_bytes,
};
futures.push(async move {
let _: String = canister
.update_("start", candid, input)
.update_("start", candid, (input,))
.await
.unwrap_or_else(|e| {
panic!(
Expand Down

0 comments on commit 1b65617

Please sign in to comment.