Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Timeout on a feature level #4479

Unanswered
nikzupancic asked this question in Q&A
Discussion options

I have a bigger collection of test suites which are running on remote devices using Codecept and Webdriverio. Occasionally there will be an issue where devices will stop responding or start responding much slower than usual. In these cases I want to limit the execution time on a Feature level. I can do this outside of Codecept by just forcibly killing the process once it reaches the timeout however this will leave me with no logs/reports for tests in that feature.

I've looked at the timeouts section in docs but this is geared more towards setting timeouts for each test. This is not feasible for me because in worst case scenarios certain steps can get stuck for more than 2 mins - test timeouts would help to a certain degree but if I have 5 tests timing out in a row it will still add on quite some time to get through all of them.

As I reset the connection to device after each feature is finished setting timeout on a feature level would be much more useful for me: if the whole feature is running for more than 4 mins I'm fairly confident that the result wouldn't be useful and I would need to rerun it anyway.

Is there a way to achieve this kind of timeout in Codecept? One thing I haven't yet considered is creating a custom plugin that would monitor the time since start of suite and compare it to a limit set in config and then just throw an error if that limit has been reached. I'm curious though if anyone has ever tackled something like this and has some input.

You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /