gridium 0.1.6 → 0.1.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/element.rb +13 -5
- data/lib/gridium/version.rb +1 -1
- data/lib/page.rb +2 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: eefb67c054454fc770901e82fc48562a69983c0f
|
4
|
+
data.tar.gz: 691a38ba1a6927f33596de5739512a1a64e9d281
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 46f188677f67d98523ccd4b771e60fc3b8abc6f0a0d7697b50e04e6f3cbead6590504e30af15ce9b8ec22d3829d43463301815942db26186b8ab52740aded3cd
|
7
|
+
data.tar.gz: 874e0ccf750bc76e3e562f8e9a9339b7d186b7ff15455fbf427fa364e7f166ab4fbd0cd9a6d28a6dd694c720f3c8493208af467556a1fc37d8d7ebbf076801f4
|
data/lib/element.rb
CHANGED
@@ -39,13 +39,20 @@ class Element
|
|
39
39
|
|
40
40
|
def displayed_element
|
41
41
|
found_element = nil
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
42
|
+
#Found an issue where the element would go stale after it's found
|
43
|
+
begin
|
44
|
+
elements = @driver.find_elements(@by, @locator)
|
45
|
+
##there's a chance here the element is found but not displayed.
|
46
|
+
elements.each do |element|
|
47
|
+
if element.displayed? and element.enabled?
|
48
|
+
found_element = element;
|
49
|
+
end
|
47
50
|
end
|
51
|
+
rescue Exception => e
|
52
|
+
Log.warn("A Crusty old element was detected.... #{self.to_s}")
|
53
|
+
retry
|
48
54
|
end
|
55
|
+
|
49
56
|
return found_element
|
50
57
|
end
|
51
58
|
|
@@ -247,6 +254,7 @@ class Element
|
|
247
254
|
return false
|
248
255
|
end
|
249
256
|
rescue Exception => e
|
257
|
+
Log.warn("Stale element detected.... #{self.to_s}")
|
250
258
|
return true
|
251
259
|
end
|
252
260
|
end
|
data/lib/gridium/version.rb
CHANGED
data/lib/page.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gridium
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Seth Urban
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-09-
|
11
|
+
date: 2015-09-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|