pincers 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pincers/core/root_context.rb +8 -3
- data/lib/pincers/version.rb +1 -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: 630d90affa2488ca53b79f63643a3257618dfb9f
|
4
|
+
data.tar.gz: 1b8cf519322c4e69c0f2219a51a1d8e587aecd70
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 29398e9d922ad46cab2754b9b249fd5b13588a80d0f8c3ad94208d57df72bf478b6e782da2ba9b9c18bd0f584db66f3f04ae7a10320adb91ca85eadc8b001a16
|
7
|
+
data.tar.gz: 8008abec35682cf438e7bd7a65a9cdaa3fad368167fb0051fd73b045edfa8ffe8c2f586807d684e33c291b950eb52d1ba6730a5decc66e7488d9aa4911e4f944
|
@@ -42,10 +42,10 @@ module Pincers::Core
|
|
42
42
|
_urlOrOptions = { url: _urlOrOptions }
|
43
43
|
end
|
44
44
|
|
45
|
-
if _urlOrOptions.key? :
|
45
|
+
if _urlOrOptions.key? :url
|
46
|
+
goto_url _urlOrOptions[:url]
|
47
|
+
elsif _urlOrOptions.key? :frame
|
46
48
|
goto_frame _urlOrOptions[:frame]
|
47
|
-
elsif _urlOrOptions.key? :url
|
48
|
-
backend.navigate_to _urlOrOptions[:url]
|
49
49
|
else
|
50
50
|
raise ArgumentError.new "Must provide a valid target when calling 'goto'"
|
51
51
|
end
|
@@ -78,6 +78,11 @@ module Pincers::Core
|
|
78
78
|
|
79
79
|
private
|
80
80
|
|
81
|
+
def goto_url(_url)
|
82
|
+
_url = "http://#{_url}" unless /^(https?|file|ftp):\/\// === _url
|
83
|
+
backend.navigate_to _url
|
84
|
+
end
|
85
|
+
|
81
86
|
def goto_frame(_frame)
|
82
87
|
case _frame
|
83
88
|
when :top
|
data/lib/pincers/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pincers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ignacio Baixas
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-08-
|
11
|
+
date: 2015-08-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: selenium-webdriver
|