Bug 1444068 - Make Marionette connection polling stop at timeout r=ato
MozReview-Commit-ID: 1Nt8LBLoNyR
--- a/testing/geckodriver/src/marionette.rs
+++ b/testing/geckodriver/src/marionette.rs
@@ -1347,17 +1347,17 @@ impl MarionetteConnection {
}
match TcpStream::connect(&(DEFAULT_HOST, self.port)) {
Ok(stream) => {
self.stream = Some(stream);
break;
}
Err(e) => {
- if now.elapsed() <= timeout {
+ if now.elapsed() < timeout {
thread::sleep(poll_interval);
} else {
return Err(WebDriverError::new(
ErrorStatus::UnknownError,
e.description().to_owned(),
));
}
}