capybara-slow_finder_errors 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5408b07ad5d32cdf3f45dcae687569cb2156b700
4
- data.tar.gz: 8750ee9ebdbb859dccd254050afdad37cabe8b81
3
+ metadata.gz: e0a76008467cd65b247e0e43dd26ad5d4b1ea392
4
+ data.tar.gz: e4ce683a6b52d1f48abc7c8dd057bc008ffdb295
5
5
  SHA512:
6
- metadata.gz: 876319a7a881519ba2adb705cc119256070df010e2636cc243d1790e2f5264d2d27942a8e8c02b252ecb7833f9cf3436b05f5a98257db423ef640910ac79db47
7
- data.tar.gz: 078c29ea8a2dacb349857c78c3b51d5b2cd27eedd2230e1e699acdf82543a10c6a46d028d40b7319f8054c940ffaf3b23cfb026136d51ba11f5fb79b86772084
6
+ metadata.gz: 1f8b162b715187577ce10b6532ba03ab9d4a9bf9f61889ab652222a4df085145aca62fa76500523c8484c190b28badf733f422bceedc873bb5c6dbd8c50d8178
7
+ data.tar.gz: d76bbaf24afe98c9ef88fc4831ae5bf8fac6cfce16fcb30a8f9d6fce06adb2028ac7de336f83547a72295f541fb8ad8c1afdf09d7e03bbbe2359efa5bd33455b
data/README.md CHANGED
@@ -97,7 +97,7 @@ Returns true if they are signed in, but it waits a full timeout before returning
97
97
  ```ruby
98
98
  def signed_in?
99
99
  page.has_content?("Dashboard")
100
- page.all('a', :text => 'Home').any?
100
+ page.has_css?('a', :text => 'Home', :wait => false)
101
101
  end
102
102
  ```
103
103
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "capybara-slow_finder_errors"
5
- spec.version = "0.1.1"
5
+ spec.version = "0.1.2"
6
6
  spec.authors = ["Nick Gauthier"]
7
7
  spec.email = ["ngauthier@gmail.com"]
8
8
  spec.summary = %q{Raises an error when you use a Capybara finder improperly}
@@ -9,7 +9,7 @@ module Capybara
9
9
  synchronize_without_timeout_error(*args, &block)
10
10
  rescue Capybara::ElementNotFound => e
11
11
  seconds = args.first || Capybara.default_wait_time
12
- if Time.now-start_time > seconds
12
+ if seconds > 0 && Time.now-start_time > seconds
13
13
  raise SlowFinderError, "Timeout reached while running a *waiting* Capybara finder...perhaps you wanted to return immediately? Use a non-waiting Capybara finder. More info: http://blog.codeship.com/faster-rails-tests?utm_source=gem_exception"
14
14
  end
15
15
  raise
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capybara-slow_finder_errors
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Gauthier
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-03 00:00:00.000000000 Z
11
+ date: 2014-12-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler