softwear-lib 0.0.17 → 0.0.18
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/softwear/lib/spec.rb +17 -0
- data/lib/softwear/lib/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 984dca4944083eaf9ffe3deb14435844549a02f7
|
4
|
+
data.tar.gz: c4ed96eb930b965e462b0fa38123487d338cbd18
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce35f4b0c99335ed65f7d571a660674c43ebf804e172fd6eb8a14efaffd20d2315830e7937c2829e206db9a922d79e0eb3b1cba2a7b00813ad8026b30a04b799
|
7
|
+
data.tar.gz: 329d770225ba1ed633e0e07f35a75c375fe6f7788cacde110b56f67e76bc6d9cafbd24f9642f02a1a8db8bef6aab2935a313bf62a3311ff1d5ba3afb74619628
|
data/lib/softwear/lib/spec.rb
CHANGED
@@ -118,6 +118,23 @@ module Softwear::Lib
|
|
118
118
|
targetted_select2(value, options)
|
119
119
|
end
|
120
120
|
|
121
|
+
def nogood_select2(value, from)
|
122
|
+
label = find_label_by_text(from[:from])
|
123
|
+
|
124
|
+
select2_container = nil
|
125
|
+
within label.first(:xpath,'.//..') do
|
126
|
+
select2_container = find('.select2-container')
|
127
|
+
end
|
128
|
+
|
129
|
+
select2_container.find(".select2-choice").click
|
130
|
+
|
131
|
+
find(:xpath, "//body").find("input.select2-input").set(value)
|
132
|
+
page.execute_script(%|$("input.select2-input:visible").keyup();|)
|
133
|
+
drop_container = ".select2-results"
|
134
|
+
find(:xpath, "//body").find("#{drop_container} li", text: value).click
|
135
|
+
end
|
136
|
+
|
137
|
+
|
121
138
|
def select2_no_label value, options={}
|
122
139
|
raise "Must pass a hash containing 'from'" if not options.is_a?(Hash) or not options.has_key?(:from)
|
123
140
|
|
data/lib/softwear/lib/version.rb
CHANGED