Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
7bd8411
GH-690: add boilerplate for --min-hops command
utkarshg6 Apr 6, 2023
065f0aa
GH-690: populate necessary code for the command
utkarshg6 Apr 6, 2023
0e857bd
GH-690: add the command to schema
utkarshg6 Apr 6, 2023
65bd6d7
GH-690: allow Neighborhood to process the --min-hops command
utkarshg6 Apr 11, 2023
0095658
GH-690: add min_hops_count as a field inside NeighborhoodConfig
utkarshg6 Apr 11, 2023
acc284f
GH-690: add min-hops to shared_schema.rs
utkarshg6 Apr 13, 2023
814b521
GH-690: use --min-hops while building NeighborhoodConfig
utkarshg6 Apr 13, 2023
0ac9394
GH-690: remove min-hops as a command
utkarshg6 Apr 14, 2023
441adeb
GH-690: make min_hops_count a field of Neighborhood
utkarshg6 Apr 17, 2023
0558bbc
GH-690: pass min_hops_count from Neighborhood to GossipHandler
utkarshg6 Apr 17, 2023
ea42650
GH-690: add NeighborhoodMetadata inside gossip_acceptor.rs
utkarshg6 Apr 17, 2023
a6f7708
GH-690: receive cpm_recipient from handle_agrs() instead of storing i…
utkarshg6 Apr 18, 2023
fbad5e1
GH-690: remove cpm_recipient from gossip_acceptor
utkarshg6 Apr 18, 2023
80cab88
GH-690: generate gossip_acceptor and gossip_producer inside Neighborh…
utkarshg6 Apr 18, 2023
4c05781
GH-690: store hops count as an enum
utkarshg6 Apr 19, 2023
638b196
GH-690: write tests to handle the default and error case for --min-hops
utkarshg6 Apr 20, 2023
c33e722
GH-690: add a TODO for the new regex inside make_configurator_error
utkarshg6 Apr 20, 2023
7b42700
GH-690: compute patch for different min hops count
utkarshg6 Apr 21, 2023
f0053c2
GH-690: rename HopsCount to Hops
utkarshg6 Apr 24, 2023
14708fd
GH-690: write tests for testing route query message for different hops
utkarshg6 Apr 24, 2023
51181b8
GH-690: remove a todo
utkarshg6 Apr 25, 2023
ff32811
GH-690: write tests for connectivity check
utkarshg6 Apr 25, 2023
c220536
GH-690: remove the duplicate test
utkarshg6 Apr 25, 2023
e8748ab
GH-690: change the stage to RouteFound from ThreeHopsRouteFound
utkarshg6 Apr 25, 2023
50e62c4
GH-690: formatting changes
utkarshg6 Apr 25, 2023
2dc04c6
GH-690: remove unnecessary comments
utkarshg6 Apr 25, 2023
50b3048
GH-690: fix the multionde test
utkarshg6 Apr 25, 2023
6eb1b25
GH-690: add min_hops_count as a field inside NodeStartupConfig for mu…
utkarshg6 Apr 26, 2023
61c194a
GH-690: allow NodeStartupConfigBuilder to copy the min_hops_count fro…
utkarshg6 Apr 27, 2023
99b7ee4
GH-690: fix the problem of accidentally defaulting the min_hops_count
utkarshg6 Apr 27, 2023
47342e3
GH-690: write multinode test for testing Node with different min_hops…
utkarshg6 Apr 27, 2023
30101d3
GH-690: use Into implementation for NeighborhoodModeLight
utkarshg6 Apr 27, 2023
c18a839
GH-690: get min_hops_count from Neighborhood instad of RouteQueryMessage
utkarshg6 Apr 28, 2023
9b3e340
GH-690: remove unnecessary comments and write todos
utkarshg6 Apr 28, 2023
2accfee
GH-690: remove warnings; all unit tests for Node/node is passing
utkarshg6 Apr 28, 2023
673c639
GH-690: use MIN_HOPS_COUNT_FOR_TEST instead of DEFAULT_MIN_HOPS_COUNT…
utkarshg6 May 1, 2023
433eee7
GH-690: the multinode test for data routing test for different min ho…
utkarshg6 May 1, 2023
b07c9cc
GH-690: optimize the data routing test for different min_hops_count
utkarshg6 May 1, 2023
8764839
GH-690: use higher timeout for the client inisde the data routing tes…
utkarshg6 May 1, 2023
a4a664a
GH-690: improve the help message for the --min-hops count
utkarshg6 May 2, 2023
ce1b9a6
GH-690: remove the working fine text and improve the comment
utkarshg6 May 2, 2023
7317131
GH-690: refactor out functions from assert_compute_patch
utkarshg6 May 2, 2023
35eb8e5
GH-690: refactor assert_route_query_message()
utkarshg6 May 3, 2023
717f29b
GH-690: refactor make_neighborhood_with_linearly_connected_nodes()
utkarshg6 May 3, 2023
bc1216e
GH-690: cleanup in connectivity check
utkarshg6 May 3, 2023
a5ac707
GH-690: make --min-hops configurable via cli
utkarshg6 May 3, 2023
f6f5991
GH-690: fix the bump script for macOS
utkarshg6 May 4, 2023
05ae02b
GH-690: add todo for the min-hops arg to default properly
utkarshg6 May 4, 2023
65db4f2
GH-690: add todo inisde unpriveleged args
utkarshg6 May 4, 2023
0273dcb
GH-690: change the min_values to 0 for min-hops
utkarshg6 May 5, 2023
1cf77ba
GH-690: cleanup in node_configurator
utkarshg6 May 5, 2023
91a4c1a
GH-690: cleanup in proxy server
utkarshg6 May 5, 2023
250614f
GH-690: formatting
utkarshg6 May 5, 2023
02d7704
GH-690: allow clippy warning for from_over_into
utkarshg6 May 5, 2023
e9e4b25
GH-690: disable console diagnostics
utkarshg6 May 5, 2023
b73238d
GH-690: improve expect message if pulling out min_hops_count fails
utkarshg6 May 5, 2023
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
2 changes: 1 addition & 1 deletion ci/bump_version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ bump_version() {
find_pattern='^version\s*=.*[^,]\s*$'
replace_pattern='s/'$find_pattern'/version = "'"$version"'"/'

grep -q "$find_pattern" "$file" && sed -i "$replace_pattern" "$file"
grep -q "$find_pattern" "$file" && sed -i "" "$replace_pattern" "$file"
exit_code="$?"
if [[ "$exit_code" != "0" ]]; then
final_exit_code=1
Expand Down
16 changes: 6 additions & 10 deletions masq/src/commands/connection_status_command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@ const CONNECTION_STATUS_ABOUT: &str =
const NOT_CONNECTED_MSG: &str = "NotConnected: No external neighbor is connected to us.";
const CONNECTED_TO_NEIGHBOR_MSG: &str =
"ConnectedToNeighbor: External neighbor(s) are connected to us.";
const THREE_HOPS_ROUTE_FOUND_MSG: &str =
"ThreeHopsRouteFound: You can relay data over the network.";
const ROUTE_FOUND_MSG: &str = "RouteFound: You can relay data over the network.";

pub fn connection_status_subcommand() -> App<'static, 'static> {
SubCommand::with_name("connection-status").about(CONNECTION_STATUS_ABOUT)
Expand All @@ -42,7 +41,7 @@ impl Command for ConnectionStatusCommand {
let stdout_msg = match response.stage {
UiConnectionStage::NotConnected => NOT_CONNECTED_MSG,
UiConnectionStage::ConnectedToNeighbor => CONNECTED_TO_NEIGHBOR_MSG,
UiConnectionStage::ThreeHopsRouteFound => THREE_HOPS_ROUTE_FOUND_MSG,
UiConnectionStage::RouteFound => ROUTE_FOUND_MSG,
};
short_writeln!(context.stdout(), "\n{}\n", stdout_msg);
Ok(())
Expand Down Expand Up @@ -109,8 +108,8 @@ mod tests {
"ConnectedToNeighbor: External neighbor(s) are connected to us."
);
assert_eq!(
THREE_HOPS_ROUTE_FOUND_MSG,
"ThreeHopsRouteFound: You can relay data over the network."
ROUTE_FOUND_MSG,
"RouteFound: You can relay data over the network."
)
}

Expand Down Expand Up @@ -164,11 +163,8 @@ mod tests {
#[test]
fn connection_status_command_happy_path_for_three_hops_route_found() {
assert_on_connection_status_response(
UiConnectionStage::ThreeHopsRouteFound,
(
"\nThreeHopsRouteFound: You can relay data over the network.\n\n",
"",
),
UiConnectionStage::RouteFound,
("\nRouteFound: You can relay data over the network.\n\n", ""),
);
}

Expand Down
4 changes: 2 additions & 2 deletions masq/src/notifications/connection_change_notification.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ impl ConnectionChangeNotification {
UiConnectionStage::ConnectedToNeighbor => {
"\nConnectedToNeighbor: Established neighborship with an external node.\n"
}
UiConnectionStage::ThreeHopsRouteFound => {
UiConnectionStage::RouteFound => {
"\nThreeHopsRouteFound: You can now relay data over the network.\n"
}
};
Expand Down Expand Up @@ -63,7 +63,7 @@ mod tests {
let mut stdout = ByteArrayWriter::new();
let stderr = ByteArrayWriter::new();
let msg = UiConnectionChangeBroadcast {
stage: UiConnectionStage::ThreeHopsRouteFound,
stage: UiConnectionStage::RouteFound,
};
let term_interface = TerminalWrapper::new(Arc::new(TerminalPassiveMock::new()));

Expand Down
2 changes: 1 addition & 1 deletion masq_lib/src/messages.rs
Original file line number Diff line number Diff line change
Expand Up @@ -550,7 +550,7 @@ pub struct UiPaymentThresholds {
pub enum UiConnectionStage {
NotConnected,
ConnectedToNeighbor,
ThreeHopsRouteFound,
RouteFound,
}

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq)]
Expand Down
7 changes: 7 additions & 0 deletions masq_lib/src/multi_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,13 @@ impl<'a> MultiConfig<'a> {
let message = format!("Invalid value: {}", &captures[2]);
return ConfiguratorError::required(name, &message);
}
let another_invalid_value_regex =
Regex::new("error: (.*) isn't a valid value for '--(.*?) <.*>'").expect("Bad regex"); // TODO: is this good enough?
if let Some(captures) = another_invalid_value_regex.captures(&e.message) {
let name = &captures[2];
let message = format!("Invalid value: {}", &captures[1]);
return ConfiguratorError::required(name, &message);
}
if e.message
.contains("The following required arguments were not provided:")
{
Expand Down
45 changes: 45 additions & 0 deletions masq_lib/src/shared_schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,22 @@ pub const MAPPING_PROTOCOL_HELP: &str =
public IP address with the --ip parameter. If the Node communicates successfully with your router, \
it will remember the protocol it used, and on its next run it will try that protocol first, unless \
you specify a different protocol on the command line.";
pub const MIN_HOPS_HELP: &str =
"The Node is a system that routes data through multiple Nodes to enhance security and privacy. \
However, the level of anonymity and security provided depends on the number of hops specified \
by the user. By default, the system allows the user to customize the number of hops within a \
range of 1 to 6.\n\n\
It's important to note that if the user selects less than 3 hops, the anonymity of their data \
cannot be guaranteed. Here's a breakdown of the different hop counts and their implications:\n\n\
1. A 1-hop route allows Exit Nodes to see your requests.\n\
2. A 2-hop route makes it harder to associate your requests with your IP address, but it's \
not a foolproof guarantee.\n\
3. The minimum number of hops required to guarantee anonymity is 3.\n\
4. Increasing the number of hops to 4, 5, or 6 can enhance security, but it will also \
increase the cost and latency of the route.\n\
If you want to specify a minimum hops count, you can do so by entering a number after the \
'--min-hops' command. For example, '--min-hops 4' would require at least 4 hops. If you fail \
to provide this argument, the system will default to a minimum hops count of 3.";
pub const REAL_USER_HELP: &str =
"The user whose identity Node will assume when dropping privileges after bootstrapping. Since Node refuses to \
run with root privilege after bootstrapping, you might want to use this if you start the Node as root, or if \
Expand Down Expand Up @@ -407,6 +423,17 @@ pub fn shared_app(head: App<'static, 'static>) -> App<'static, 'static> {
.case_insensitive(true)
.help(MAPPING_PROTOCOL_HELP),
)
.arg(
Arg::with_name("min-hops")
.long("min-hops")
.value_name("MIN_HOPS")
.default_value("3")
.required(false)
.min_values(0)
.max_values(1)
.possible_values(&["1", "2", "3", "4", "5", "6"])
.help(MIN_HOPS_HELP),
)
.arg(
Arg::with_name("neighborhood-mode")
.long("neighborhood-mode")
Expand Down Expand Up @@ -764,6 +791,24 @@ mod tests {
it will remember the protocol it used, and on its next run it will try that protocol first, unless \
you specify a different protocol on the command line."
);
assert_eq!(
MIN_HOPS_HELP,
"The Node is a system that routes data through multiple Nodes to enhance security and privacy. \
However, the level of anonymity and security provided depends on the number of hops specified \
by the user. By default, the system allows the user to customize the number of hops within a \
range of 1 to 6.\n\n\
It's important to note that if the user selects less than 3 hops, the anonymity of their data \
cannot be guaranteed. Here's a breakdown of the different hop counts and their implications:\n\n\
1. A 1-hop route allows Exit Nodes to see your requests.\n\
2. A 2-hop route makes it harder to associate your requests with your IP address, but it's \
not a foolproof guarantee.\n\
3. The minimum number of hops required to guarantee anonymity is 3.\n\
4. Increasing the number of hops to 4, 5, or 6 can enhance security, but it will also \
increase the cost and latency of the route.\n\
If you want to specify a minimum hops count, you can do so by entering a number after the \
'--min-hops' command. For example, '--min-hops 4' would require at least 4 hops. If you fail \
to provide this argument, the system will default to a minimum hops count of 3."
);
assert_eq!(
REAL_USER_HELP,
"The user whose identity Node will assume when dropping privileges after bootstrapping. Since Node refuses to \
Expand Down
2 changes: 1 addition & 1 deletion multinode_integration_tests/src/masq_cores_client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ impl<'a> MASQCoresClient<'a> {
pub fn new(socket_addr: SocketAddr, cryptde: &'a dyn CryptDE) -> MASQCoresClient<'a> {
MASQCoresClient {
cryptde,
delegate: MASQNodeClient::new(socket_addr),
delegate: MASQNodeClient::new(socket_addr, 1000),
}
}

Expand Down
4 changes: 2 additions & 2 deletions multinode_integration_tests/src/masq_node_client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pub struct MASQNodeClient {
}

impl MASQNodeClient {
pub fn new(socket_addr: SocketAddr) -> MASQNodeClient {
pub fn new(socket_addr: SocketAddr, timeout_millis: u64) -> MASQNodeClient {
let stream = TcpStream::connect(&socket_addr)
.unwrap_or_else(|_| panic!("Connecting to {}", socket_addr));
stream
Expand All @@ -20,7 +20,7 @@ impl MASQNodeClient {

MASQNodeClient {
stream,
timeout: Duration::from_secs(1),
timeout: Duration::from_millis(timeout_millis),
}
}

Expand Down
30 changes: 27 additions & 3 deletions multinode_integration_tests/src/masq_real_node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,13 @@ use masq_lib::test_utils::utils::TEST_DEFAULT_MULTINODE_CHAIN;
use masq_lib::utils::localhost;
use masq_lib::utils::{DEFAULT_CONSUMING_DERIVATION_PATH, DEFAULT_EARNING_DERIVATION_PATH};
use node_lib::blockchain::bip32::Bip32ECKeyProvider;
use node_lib::neighborhood::DEFAULT_MIN_HOPS_COUNT;
use node_lib::sub_lib::accountant::{
PaymentThresholds, DEFAULT_EARNING_WALLET, DEFAULT_PAYMENT_THRESHOLDS,
};
use node_lib::sub_lib::cryptde::{CryptDE, PublicKey};
use node_lib::sub_lib::cryptde_null::CryptDENull;
use node_lib::sub_lib::neighborhood::{RatePack, DEFAULT_RATE_PACK, ZERO_RATE_PACK};
use node_lib::sub_lib::neighborhood::{Hops, RatePack, DEFAULT_RATE_PACK, ZERO_RATE_PACK};
use node_lib::sub_lib::node_addr::NodeAddr;
use node_lib::sub_lib::wallet::Wallet;
use regex::Regex;
Expand All @@ -36,6 +37,7 @@ use std::thread;
use std::time::Duration;

pub const DATA_DIRECTORY: &str = "/node_root/home";
pub const STANDARD_CLIENT_TIMEOUT_MILLIS: u64 = 1000;

#[derive(Clone, Debug, PartialEq, Eq)]
pub struct Firewall {
Expand Down Expand Up @@ -112,6 +114,7 @@ pub fn make_consuming_wallet_info(token: &str) -> ConsumingWalletInfo {
#[derive(PartialEq, Eq, Clone, Debug)]
pub struct NodeStartupConfig {
pub neighborhood_mode: String,
pub min_hops_count: Hops,
pub ip_info: LocalIpInfo,
pub dns_servers_opt: Option<Vec<IpAddr>>,
pub neighbors: Vec<NodeReference>,
Expand Down Expand Up @@ -143,6 +146,7 @@ impl NodeStartupConfig {
pub fn new() -> NodeStartupConfig {
NodeStartupConfig {
neighborhood_mode: "standard".to_string(),
min_hops_count: DEFAULT_MIN_HOPS_COUNT,
ip_info: LocalIpInfo::ZeroHop,
dns_servers_opt: None,
neighbors: Vec::new(),
Expand Down Expand Up @@ -174,6 +178,8 @@ impl NodeStartupConfig {
let mut args = vec![];
args.push("--neighborhood-mode".to_string());
args.push(self.neighborhood_mode.clone());
args.push("--min-hops".to_string());
args.push(format!("{}", self.min_hops_count as usize));
if let LocalIpInfo::DistributedKnown(ip_addr) = self.ip_info {
args.push("--ip".to_string());
args.push(ip_addr.to_string());
Expand Down Expand Up @@ -403,6 +409,7 @@ impl NodeStartupConfig {

pub struct NodeStartupConfigBuilder {
neighborhood_mode: String,
min_hops_count: Hops,
ip_info: LocalIpInfo,
dns_servers_opt: Option<Vec<IpAddr>>,
neighbors: Vec<NodeReference>,
Expand Down Expand Up @@ -458,6 +465,7 @@ impl NodeStartupConfigBuilder {
pub fn standard() -> Self {
Self {
neighborhood_mode: "standard".to_string(),
min_hops_count: DEFAULT_MIN_HOPS_COUNT,
ip_info: LocalIpInfo::DistributedUnknown,
dns_servers_opt: None,
neighbors: vec![],
Expand All @@ -483,6 +491,7 @@ impl NodeStartupConfigBuilder {
pub fn copy(config: &NodeStartupConfig) -> Self {
Self {
neighborhood_mode: config.neighborhood_mode.clone(),
min_hops_count: config.min_hops_count,
ip_info: config.ip_info,
dns_servers_opt: config.dns_servers_opt.clone(),
neighbors: config.neighbors.clone(),
Expand Down Expand Up @@ -521,6 +530,11 @@ impl NodeStartupConfigBuilder {
}
}

pub fn min_hops_count(mut self, value: Hops) -> Self {
self.min_hops_count = value;
self
}

pub fn ip(mut self, value: IpAddr) -> Self {
self.ip_info = LocalIpInfo::DistributedKnown(value);
self
Expand Down Expand Up @@ -634,6 +648,7 @@ impl NodeStartupConfigBuilder {
pub fn build(self) -> NodeStartupConfig {
NodeStartupConfig {
neighborhood_mode: self.neighborhood_mode,
min_hops_count: self.min_hops_count,
ip_info: self.ip_info,
dns_servers_opt: self.dns_servers_opt,
neighbors: self.neighbors,
Expand Down Expand Up @@ -926,9 +941,9 @@ impl MASQRealNode {
}
}

pub fn make_client(&self, port: u16) -> MASQNodeClient {
pub fn make_client(&self, port: u16, timeout_millis: u64) -> MASQNodeClient {
let socket_addr = SocketAddr::new(self.ip_address(), port);
MASQNodeClient::new(socket_addr)
MASQNodeClient::new(socket_addr, timeout_millis)
}

pub fn make_server(&self, port: u16) -> MASQNodeServer {
Expand Down Expand Up @@ -1226,6 +1241,7 @@ mod tests {
use masq_lib::constants::{HTTP_PORT, TLS_PORT};
use masq_lib::test_utils::utils::TEST_DEFAULT_MULTINODE_CHAIN;
use masq_lib::utils::localhost;
use node_lib::sub_lib::neighborhood::Hops::TwoHops;

#[test]
fn node_startup_config_builder_zero_hop() {
Expand Down Expand Up @@ -1289,6 +1305,7 @@ mod tests {

#[test]
fn node_startup_config_builder_settings() {
let min_hops_count = Hops::SixHops;
let ip_addr = IpAddr::from_str("1.2.3.4").unwrap();
let one_neighbor_key = PublicKey::new(&[1, 2, 3, 4]);
let one_neighbor_ip_addr = IpAddr::from_str("4.5.6.7").unwrap();
Expand Down Expand Up @@ -1317,6 +1334,7 @@ mod tests {
let dns_target = IpAddr::from_str("8.9.10.11").unwrap();

let result = NodeStartupConfigBuilder::standard()
.min_hops_count(min_hops_count)
.ip(ip_addr)
.dns_servers(dns_servers.clone())
.neighbor(neighbors[0].clone())
Expand All @@ -1325,6 +1343,7 @@ mod tests {
.dns_port(35)
.build();

assert_eq!(result.min_hops_count, min_hops_count);
assert_eq!(result.ip_info, LocalIpInfo::DistributedKnown(ip_addr));
assert_eq!(result.dns_servers_opt, Some(dns_servers));
assert_eq!(result.neighbors, neighbors);
Expand All @@ -1337,6 +1356,7 @@ mod tests {
fn node_startup_config_builder_copy() {
let original = NodeStartupConfig {
neighborhood_mode: "consume-only".to_string(),
min_hops_count: TwoHops,
ip_info: LocalIpInfo::DistributedUnknown,
dns_servers_opt: Some(vec![IpAddr::from_str("255.255.255.255").unwrap()]),
neighbors: vec![NodeReference::new(
Expand Down Expand Up @@ -1415,6 +1435,7 @@ mod tests {
.build();

assert_eq!(result.neighborhood_mode, neighborhood_mode);
assert_eq!(result.min_hops_count, Hops::TwoHops);
assert_eq!(result.ip_info, LocalIpInfo::DistributedKnown(ip_addr));
assert_eq!(result.dns_servers_opt, Some(dns_servers));
assert_eq!(result.neighbors, neighbors);
Expand Down Expand Up @@ -1481,6 +1502,7 @@ mod tests {

let subject = NodeStartupConfigBuilder::standard()
.neighborhood_mode("consume-only")
.min_hops_count(Hops::SixHops)
.ip(IpAddr::from_str("1.3.5.7").unwrap())
.neighbor(one_neighbor.clone())
.neighbor(another_neighbor.clone())
Expand All @@ -1496,6 +1518,8 @@ mod tests {
Command::strings(vec!(
"--neighborhood-mode",
"consume-only",
"--min-hops",
"6",
"--ip",
"1.3.5.7",
"--neighbors",
Expand Down
4 changes: 2 additions & 2 deletions multinode_integration_tests/tests/connection_progress_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ fn connection_progress_is_properly_broadcast() {
let message_body =
ui_client.wait_for_specific_broadcast(vec!["connectionChange"], Duration::from_secs(5));
let (ccb, _) = UiConnectionChangeBroadcast::fmb(message_body).unwrap();
assert_eq!(ccb.stage, UiConnectionStage::ThreeHopsRouteFound);
assert_eq!(ccb.stage, UiConnectionStage::RouteFound);
} else {
assert_eq!(ccb.stage, UiConnectionStage::ThreeHopsRouteFound);
assert_eq!(ccb.stage, UiConnectionStage::RouteFound);
}
}

Expand Down
Loading