I'm working with JavaScript and Selenium to automate some tasks on a webpage I use a lot on Chrome.
The webpage has a form field which has some sort of embedded waiting time. After you finished typing, it waits like 10 seconds to give you the answer you need.
I think it's a mechanism similar to the one describe on the answer to this question (Run javascript function when user finishes typing instead of on key up?). It's clearly design to wait the user to finish typing. But when someone is using Selenium to fill the form, it`s not necessary at all.
I would like that Selenium could input the value on the field and the page would instantaneously give me the answer. How could I do that?
I thought that maybe it would be possible to speed up the time passing of the browser? Maybe by running a script on Selenium or on the Console of Chrome itself?
I've tried already to change the browser time after I typed something, like suggested here: Change browser time to test return value of Date()?. And I`ve tried to change the Windows time after I typed something. It didn’t worked. So I thought that maybe it would be possible to set Chrome so time passes faster on the browser.
Could someone teach me how to do that? Or does someone have another idea to solve this problem? Thank you!