Watir 6.0 is now available on RubyGems! Watir 6.0 is entirely implemented with Selenium 3.0, and has several new features.
To install:
or in your Gemfile:
See the Changelog for a complete list of updates.
Since Watir 6.0 Beta 5 there have been two significant additions.
Automatic Waits
A more thorough explanation surrounding the reasons for this change can be found on this Watirtight Testing post.
This feature helps synchronize test code with the website by making additional effort to type the things and click the things written in the tests. If your test times have increased significantly, take a look at the Watir 6 FAQ.
Updated Wait methods
#when_present
is gone, and #wait_until
and #wait_while
have gotten
more powerful.
You shouldn’t need #when_present
, but if you do, you can use the new
implementation of #wait_until_present
, which returns the object
being waited for to allow for use in chaining.
Here are some examples of the ways that the new #wait_until
and
#wait_while
methods can be used: