Skip to content

Commit

Permalink
Change port numbers to allow tests to run concurrently
Browse files Browse the repository at this point in the history
  • Loading branch information
oteffahi committed May 29, 2024
1 parent 0a03e99 commit f91e885
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions zenoh/tests/acl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ mod test {
async fn get_basic_router_config() -> Config {
let mut config = config::default();
config.set_mode(Some(WhatAmI::Router)).unwrap();
config.listen.endpoints = vec!["tcp/127.0.0.1:7447".parse().unwrap()];
config.listen.endpoints = vec!["tcp/127.0.0.1:27447".parse().unwrap()];
config.scouting.multicast.set_enabled(Some(false)).unwrap();
config
}
Expand All @@ -54,9 +54,9 @@ mod test {

async fn get_client_sessions() -> (Session, Session) {
println!("Opening client sessions");
let config = config::client(["tcp/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let config = config::client(["tcp/127.0.0.1:27447".parse::<EndPoint>().unwrap()]);
let s01 = ztimeout!(zenoh::open(config)).unwrap();
let config = config::client(["tcp/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let config = config::client(["tcp/127.0.0.1:27447".parse::<EndPoint>().unwrap()]);
let s02 = ztimeout!(zenoh::open(config)).unwrap();
(s01, s02)
}
Expand Down
18 changes: 9 additions & 9 deletions zenoh/tests/authentication.rs
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ client2name:client2passwd";
async fn get_basic_router_config_tls() -> Config {
let mut config = config::default();
config.set_mode(Some(WhatAmI::Router)).unwrap();
config.listen.endpoints = vec!["tls/127.0.0.1:7447".parse().unwrap()];
config.listen.endpoints = vec!["tls/127.0.0.1:37447".parse().unwrap()];
config.scouting.multicast.set_enabled(Some(false)).unwrap();
config
.insert_json5(
Expand All @@ -266,7 +266,7 @@ client2name:client2passwd";
async fn get_basic_router_config_quic() -> Config {
let mut config = config::default();
config.set_mode(Some(WhatAmI::Router)).unwrap();
config.listen.endpoints = vec!["quic/127.0.0.1:7447".parse().unwrap()];
config.listen.endpoints = vec!["quic/127.0.0.1:37447".parse().unwrap()];
config.scouting.multicast.set_enabled(Some(false)).unwrap();
config
.insert_json5(
Expand All @@ -293,7 +293,7 @@ client2name:client2passwd";
async fn get_basic_router_config_usrpswd() -> Config {
let mut config = config::default();
config.set_mode(Some(WhatAmI::Router)).unwrap();
config.listen.endpoints = vec!["tcp/127.0.0.1:7447".parse().unwrap()];
config.listen.endpoints = vec!["tcp/127.0.0.1:37447".parse().unwrap()];
config.scouting.multicast.set_enabled(Some(false)).unwrap();
config
.insert_json5(
Expand All @@ -318,7 +318,7 @@ client2name:client2passwd";

async fn get_client_sessions_tls() -> (Session, Session) {
println!("Opening client sessions");
let mut config = config::client(["tls/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let mut config = config::client(["tls/127.0.0.1:37447".parse::<EndPoint>().unwrap()]);
config
.insert_json5(
"transport",
Expand All @@ -339,7 +339,7 @@ client2name:client2passwd";
)
.unwrap();
let s01 = ztimeout!(zenoh::open(config)).unwrap();
let mut config = config::client(["tls/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let mut config = config::client(["tls/127.0.0.1:37447".parse::<EndPoint>().unwrap()]);
config
.insert_json5(
"transport",
Expand All @@ -365,7 +365,7 @@ client2name:client2passwd";

async fn get_client_sessions_quic() -> (Session, Session) {
println!("Opening client sessions");
let mut config = config::client(["quic/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let mut config = config::client(["quic/127.0.0.1:37447".parse::<EndPoint>().unwrap()]);
config
.insert_json5(
"transport",
Expand All @@ -386,7 +386,7 @@ client2name:client2passwd";
)
.unwrap();
let s01 = ztimeout!(zenoh::open(config)).unwrap();
let mut config = config::client(["quic/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let mut config = config::client(["quic/127.0.0.1:37447".parse::<EndPoint>().unwrap()]);
config
.insert_json5(
"transport",
Expand All @@ -412,7 +412,7 @@ client2name:client2passwd";

async fn get_client_sessions_usrpswd() -> (Session, Session) {
println!("Opening client sessions");
let mut config = config::client(["tcp/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let mut config = config::client(["tcp/127.0.0.1:37447".parse::<EndPoint>().unwrap()]);
config
.insert_json5(
"transport",
Expand All @@ -427,7 +427,7 @@ client2name:client2passwd";
)
.unwrap();
let s01 = ztimeout!(zenoh::open(config)).unwrap();
let mut config = config::client(["tcp/127.0.0.1:7447".parse::<EndPoint>().unwrap()]);
let mut config = config::client(["tcp/127.0.0.1:37447".parse::<EndPoint>().unwrap()]);
config
.insert_json5(
"transport",
Expand Down

0 comments on commit f91e885

Please sign in to comment.