Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Calls to browser.anyKindOfFunction() inside beforeCommand/afterCommand leads to infinite loop #4601
Config of WebdriverIO
Describe the bug
This works really well in v4. In v5, any call to
This applies to both
If not using browser.pause(), node will eventually run out of memory due to infinite loop.
I expect only browser commands in actual tests to trigger beforeCommand/afterCommand hooks, like in v4. Otherwise, the functionality you can perform in these hooks are severely limited.
That also loops here, so I wonder what's going on. What version of webdriver are you running? Can you use the other commands as well without issues?