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

Modify Selenium container startup detection #351

Merged
merged 4 commits into from
Jun 3, 2017

Conversation

rnorth
Copy link
Member

@rnorth rnorth commented May 30, 2017

... using alternative readiness string observed in v3.x of Selenium containers.

It seems that somewhere along the line the string that the selenium containers use to signal readiness has changed. This commit fixes that issue by allowing either string to be detected. The test tries two tag versions with differing outputs.

FYI @bsideup @kiview

@rnorth rnorth requested a review from bsideup May 30, 2017 19:15

@Test
public void testAdditionalStartupString() {
BrowserWebDriverContainer chrome = new BrowserWebDriverContainer("selenium/standalone-chrome-debug:" + tag)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can use try-with-resources here

* Simple test to check that readiness detection works correctly across major versions of the containers.
*/
@RunWith(Parameterized.class)
public class Selenium3xTest extends BaseWebDriverContainerTest {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can remove "extends BaseWebDriverContainerTest" because we don't use anything from it

@@ -56,7 +56,7 @@
*/
public BrowserWebDriverContainer() {
this.waitStrategy = new LogMessageWaitStrategy()
.withRegEx(".*RemoteWebDriver instances should connect to.*\n")
.withRegEx(".*Selenium Server is up and running.*\n")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this String available in all versions? Because I thought you wanted something like

".*(RemoteWebDriver instances should connect to)|(Selenium Server is up and running).*\n"

@rnorth rnorth merged commit 0569e0b into master Jun 3, 2017
@rnorth rnorth deleted the fix-selenium-3.x-startup-issue branch June 3, 2017 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants