Add library argument and keyword to set sleep between wait until loop
Sleep between wait until loop is an overhead to each wait loop if the appium server sits remotely. With this PR, the test execution time over the network reduce gradually.
Implements
-
Library argument to set sleep between wait until loop
-
Add Set/Get sleep between wait until loop
@serhatbolsu Could you please review and provide any feedbacks you might have?
@idxn thank you for good documentation and PR, however can you tell me again, what is the harm of default 0.2 seconds? As far as I know this is much higher in selenium.
Also in remote calls, appium is much slower then the wait time, its unlikely within that time frame something has changed already. Maybe you can compare an execution while having 0 internal sleep vs 0.2 internal sleep and post here
Here is an example. Let's say we execute the test via device cloud such as browserstack and the latency from our test runner to browserstack is 200ms. So in total, the sleep for each loop would be 400ms in minimum. This includes 200ms for latency and 200ms from internal sleep if the first iteration were missed because of false condition. If your test has 10 wait until keywords, you would waste almost 4s for 1 test. On the other hand, without internal sleep, we may waste only 2s for 1 test.
Hope that answer your questions.
Thank you @idxn