MinkExtension icon indicating copy to clipboard operation
MinkExtension copied to clipboard

saucelabs connection fails when tests are run by jenkins

Open gggeek opened this issue 9 years ago • 3 comments

This one took me a while to debug, as the test was running fine when run by hand, and failed when run via jenkins.

In short: when jenkins runs selenium tests, the Selenium2Factory sets some capabilities: tunnel-identifier, build, tags. This makes the connection to saucelabs fail (symptoms: no test running at all in saucelabs console, behat aborting with no output on the command line, our test code which is supposed to take a screenshot of the browser session creates a 0-bytes file).

I commented out the injection of tunnel-identifier, and the test now passes.

I think that the injection of capabilities should be enabled/disabled by a specific setting in the conf

gggeek avatar Dec 19 '14 16:12 gggeek

Note: a workaround is to set by hand in the yml config, in the desired capabilities, tunnel-identifier to an empty string

gggeek avatar Dec 19 '14 16:12 gggeek

Sorry for getting back to this only now, but I believe #201, that I've created recently might offer a way to solve this problem. This however will create a BC break for people expecting tunnel to be always started.

aik099 avatar Jun 20 '15 20:06 aik099

Buncha whooo haaa... took me forever to find this issue... Created a PR https://github.com/Behat/MinkExtension/pull/287

OGProgrammer avatar Aug 14 '17 23:08 OGProgrammer