Skip to content
This repository has been archived by the owner on Dec 18, 2019. It is now read-only.

On step timeout neither the onError hook nor the step retries work #167

Open
spujar opened this issue Mar 20, 2019 · 2 comments
Open

On step timeout neither the onError hook nor the step retries work #167

spujar opened this issue Mar 20, 2019 · 2 comments

Comments

@spujar
Copy link

spujar commented Mar 20, 2019

When step times out, onError hook nor the step retries work. The time is happening because of selenium not able to find the element. Below is the error captured, but we want to capture screenshots and also do a step retry

Error: function timed out, ensure the promise resolves within 90000 milliseconds
    at Timeout._onTimeout (/build/node_modules/wdio-cucumber-framework/node_modules/cucumber/src/user_code_runner.js:61:18)
    at ontimeout (timers.js:436:11)
    at tryOnTimeout (timers.js:300:5)
    at listOnTimeout (timers.js:263:5)
    at Timer.processTimers (timers.js:223:10)
@abianche
Copy link

abianche commented Jun 8, 2019

Did you find a way to workaround this problem? I would like to retry a scenario, or even a feature file, if such a timeout happens.

@BorisOsipov
Copy link
Contributor

Hi, workaround for this problem is pretty easy - make cucumberOpts.timeout greater than any wait\sleep timeouts in your tests - it will help to avoid cucumber timeouts and retries will work.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants