Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selenium: increase default startup timeout to 60 seconds #4357

Merged
Changes from 1 commit
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,7 @@ public class BrowserWebDriverContainer<SELF extends BrowserWebDriverContainer<SE

public BrowserWebDriverContainer() {
super();
final WaitStrategy logWaitStrategy = new LogMessageWaitStrategy()
.withRegEx(".*(RemoteWebDriver instances should connect to|Selenium Server is up and running).*\n")
.withStartupTimeout(Duration.of(15, SECONDS));

this.waitStrategy = new WaitAllStrategy()
.withStrategy(logWaitStrategy)
.withStrategy(new HostPortWaitStrategy())
.withStartupTimeout(Duration.of(15, SECONDS));
this.waitStrategy = getDefaultWaitStrategy();

this.withRecordingFileFactory(new DefaultRecordingFileFactory());
}
Expand All @@ -106,14 +99,7 @@ public BrowserWebDriverContainer(DockerImageName dockerImageName) {

// we assert compatibility with the chrome/firefox image later, after capabilities are processed

final WaitStrategy logWaitStrategy = new LogMessageWaitStrategy()
.withRegEx(".*(RemoteWebDriver instances should connect to|Selenium Server is up and running).*\n")
.withStartupTimeout(Duration.of(15, SECONDS));

this.waitStrategy = new WaitAllStrategy()
.withStrategy(logWaitStrategy)
.withStrategy(new HostPortWaitStrategy())
.withStartupTimeout(Duration.of(15, SECONDS));
this.waitStrategy = getDefaultWaitStrategy();

this.withRecordingFileFactory(new DefaultRecordingFileFactory());

Expand Down Expand Up @@ -383,6 +369,17 @@ public SELF withRecordingFileFactory(RecordingFileFactory recordingFileFactory)
return self();
}

private WaitStrategy getDefaultWaitStrategy() {
final WaitStrategy logWaitStrategy = new LogMessageWaitStrategy()
.withRegEx(".*(RemoteWebDriver instances should connect to|Selenium Server is up and running).*\n")
.withStartupTimeout(Duration.of(60, SECONDS));
eddumelendez marked this conversation as resolved.
Show resolved Hide resolved

return new WaitAllStrategy()
.withStrategy(logWaitStrategy)
.withStrategy(new HostPortWaitStrategy())
.withStartupTimeout(Duration.of(60, SECONDS));
eddumelendez marked this conversation as resolved.
Show resolved Hide resolved
}

public enum VncRecordingMode {
SKIP, RECORD_ALL, RECORD_FAILING
}
Expand Down