Since Watir 6.0 its internal timer class no longer has the issue watir-timecop tries to workaround. If you use Watir 6.0 and Ruby 2.3, you don't need this gem. See watir/watir#486 for details.
The problem is that internally Watir uses
Time.now when it waits for element presence/absence. Combined with Timecop, waiting gets broken because
Time.now may always returns the same value. This gem implements custom timer for Watir, which uses simple counter instead.
Add this line to your application's Gemfile:
And then execute:
Or install it yourself as:
$ gem install watir-timecop
Just require gem after Watir. That's all!
require 'watir-webdriver' require 'watir-timecop'
- Fork it ( http://github.com/p0deje/watir-timecop/fork )
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create new Pull Request
Copyright (c) 2016 Alex Rodionov. See LICENSE.txt for details.