Timeout value

I have the following in my script:

web.assertText(’//div[@id=‘layout’]/div[2]/div/p/’, ‘Test Text’, 15);

I changed the locator so that it would would not find the element. I want a timeout of 15 seconds instead of the default 60 seconds.

When I run the script it immediately fails and doesn’t wait up to the 15 seconds. If I remove the 15 seconds it waits for the default 60 seconds. How do I get it to wait for just 15 seconds when it doesn’t find the element?

Also, is there an option to change the global 60 second wait as it is too long for me?

Note: In the report it shows the duration for it was just 0.04 s.


This is quite late and hopefully you figured it out by now, but the timeout is in milliseconds, not seconds.

1 Like

Yes, I figured that out. Thanks for answering though!

1 Like