mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-18 13:28:33 +00:00
Update discv5 to expand ipv6 support (#4319)
Done in different PRs so that they can reviewed independently, as it's likely this won't be merged before I leave Includes resolution for #4080 - [ ] #4299 - [ ] #4318 - [ ] #4320 Co-authored-by: Diva M <divma@protonmail.com> Co-authored-by: Age Manning <Age@AgeManning.com>
This commit is contained in:
@@ -39,7 +39,7 @@ impl CommandLineTest {
|
||||
}
|
||||
|
||||
fn run_with_ip(&mut self) -> CompletedTest<BootNodeConfigSerialization> {
|
||||
self.cmd.arg(IP_ADDRESS);
|
||||
self.cmd.arg("--enr-address").arg(IP_ADDRESS);
|
||||
self.run()
|
||||
}
|
||||
}
|
||||
@@ -67,7 +67,13 @@ fn port_flag() {
|
||||
.flag("port", Some(port.to_string().as_str()))
|
||||
.run_with_ip()
|
||||
.with_config(|config| {
|
||||
assert_eq!(config.listen_socket.port(), port);
|
||||
assert_eq!(
|
||||
config
|
||||
.ipv4_listen_socket
|
||||
.expect("Bootnode should be listening on IPv4")
|
||||
.port(),
|
||||
port
|
||||
);
|
||||
})
|
||||
}
|
||||
|
||||
@@ -78,7 +84,13 @@ fn listen_address_flag() {
|
||||
.flag("listen-address", Some("127.0.0.2"))
|
||||
.run_with_ip()
|
||||
.with_config(|config| {
|
||||
assert_eq!(config.listen_socket.ip(), addr);
|
||||
assert_eq!(
|
||||
config
|
||||
.ipv4_listen_socket
|
||||
.expect("Bootnode should be listening on IPv4")
|
||||
.ip(),
|
||||
&addr
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user