How do I manage the execution speed.
I am not able to get the option of setting and getting speed of
execution using Webdriver object.
I tried the following code and couldnt get the method to set and get
speed.
WebDriver driver = new FirefoxDriver(firefoxProfile);
driver.manage().???
Can you pls help?
Regards,
Arun Kumaresan
Arun Kumaresan
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To post to this group, send email to seleniu...@googlegroups.com.
To unsubscribe from this group, send email to selenium-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/selenium-users?hl=en.
Adam
On Nov 21, 10:44 am, Luke Inman-Semerau <luke.seme...@gmail.com>
wrote:
> There isn't... you shouldn't. The only reason I can think of is if you are
> trying to demo the automation to someone (like management). In that case
> you can set a break point in your code and step through the execution for
> them to see... and then wow them by running it without the breakpoints to
> show them how quickly it runs ;)
>
> If you let me know your use-case I can try to recommend something.
>
> On Mon, Nov 21, 2011 at 9:17 AM, Arun Kumaresan <arunkumare...@gmail.com>wrote:
>
> > Pls correct me if I am wrong.
> > But looks like implicit and explicit waits are used only for waiting on a
> > certain object in the UI.
>
> > But that doesnt slow down the execution of the webdriver script execution
> > per se (If all the required objects are available).
>
> > I was looking for something in webdriver that is anologus to
> > selenium.setSpeed()
>
> > On Mon, Nov 21, 2011 at 9:01 AM, Luke Inman-Semerau <
> > luke.seme...@gmail.com> wrote:
>
> >> In webdriver you do not "setSpeed". You need to add waits to your code if
> >> an element is not available to be interacted with:
>
> >>http://seleniumhq.org/docs/04_webdriver_advanced.html#explicit-and-im...
>
> >> On Mon, Nov 21, 2011 at 7:40 AM, cassio kenji <chaosci...@gmail.com>wrote:
>
> >>> Hello,
>
> >>> could you try the selenium.setSpeed(String miliseconds)?
>
> >>> Hope it helps
>
> >>> 2011/11/21 Arun Kumaresan <arunkumare...@gmail.com>
With an AJAX application a click can fire off javascript that
webdriver has no way of knowing when the javascript executed has
finished. This is why you need to some sort of wait to manage the flow
of the test.
I wrote up a short article discussing waits in webdriver. This might
help:
# Get execution delay in milliseconds, i.e. a pause delay following # each selenium operation. By default, there is no such delay # (value is 0). def execution_delay string_command "getSpeed" end # Set the execution delay in milliseconds, i.e. a pause delay following # each selenium operation. By default, there is no such delay. # # Setting an execution can be useful to troubleshoot or capture videos def execution_delay=(delay_in_milliseconds) remote_control_command "setSpeed", [delay_in_milliseconds] endhttp://selenium.googlecode.com/svn/tags/selenium-2.20.0/rb/lib/selenium/client/idiomatic.rb
Hello,
could you try the selenium.setSpeed(String miliseconds)?
Hope it helps
2011/11/21 Arun Kumaresan <arunku...@gmail.com>
Hi,
I am using selenium 2.13.0.
How do I manage the execution speed.
I am not able to get the option of setting and getting speed of
execution using Webdriver object.
I tried the following code and couldnt get the method to set and get
speed.
WebDriver driver = new FirefoxDriver(firefoxProfile);
driver.manage().???
Can you pls help?
Regards,
Arun Kumaresan
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To post to this group, send email to selenium-users@googlegroups.com.
To unsubscribe from this group, send email to selenium-users+unsubscribe@googlegroups.com.
Arun, I have the same problem !Have you found a solution ??
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/selenium-users/-/YumLy0fGA9IJ.
To post to this group, send email to seleniu...@googlegroups.com.
To unsubscribe from this group, send email to selenium-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/selenium-users?hl=en.
There is no straight forward way. But there is a hack that you can use, you can override methods of webdriver and introduce a explicit sleep to slow down your tests eg. overriding findElement method
public class _WebDriver extends FirefoxDriver { @Override public WebElement findElement(By by) { try { Thread.sleep(500); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } return by.findElement((SearchContext) this); } }
}
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/04fc57ee-152e-4970-848d-541f07939f44%40googlegroups.com?hl=en-US.
For more options, visit https://groups.google.com/groups/opt_out.