cuke_master 0.1.12 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/cuke_master/steps.rb +14 -1
- data/lib/cuke_master/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: 83adc6b12650c551b1a3e70f77e5416855823947
|
4
|
+
data.tar.gz: 4a68e78276fdccf695de5478a3f5d52db66c8878
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ce80f3e8f86852be6e46aedecbfcb6c13c56ed31775b246a2b5811a5011f5c4313ed336e022cec1c4f768d693b53894c1eb3e8117b6021cdda11c1aefbb46de
|
7
|
+
data.tar.gz: e31a4daa51c017c3297bdc43bf5f93d4912b073bd5d175573078a983804cd3336c2408de6633618f6b9e59ec208e00539449455f499782c9751b15f004e37789
|
data/lib/cuke_master/steps.rb
CHANGED
@@ -307,7 +307,7 @@ Then(/^I should see tag "([^"]*)" with content "([^"]*)"$/) do |tag, content|
|
|
307
307
|
assert page.has_selector?(tag, text: content, visible: true)
|
308
308
|
end
|
309
309
|
|
310
|
-
# 4.3 Check
|
310
|
+
# 4.3 Check for attribute name vs value
|
311
311
|
# I should see tag "div" with attribute "id" filled in "james"
|
312
312
|
Then(/^I should see tag "([^"]*)" with attribute "([^"]*)" \
|
313
313
|
filled with "([^"]*)" has attribute "([^"]*)" filled with "([^"]*)"$/) \
|
@@ -320,6 +320,19 @@ do |tag, attr_name, attr_value, attr2_name, attr2_value|
|
|
320
320
|
assert el[attr2_name] == attr2_value
|
321
321
|
end
|
322
322
|
|
323
|
+
# 4.3 Check for checked checkbox
|
324
|
+
# I should see tag "div" with attribute "id" filled in "james"
|
325
|
+
Then(/^I should see checkbox with attribute "([^"]*)" \
|
326
|
+
filled with "([^"]*)" "([^"]*)"$/) \
|
327
|
+
do |attr_name, attr_value, checked_cond|
|
328
|
+
Capybara.ignore_hidden_elements = false
|
329
|
+
el = first(:xpath, ".//input[@#{attr_name}='#{attr_value}']")
|
330
|
+
Capybara.ignore_hidden_elements = true
|
331
|
+
assert !el.nil?
|
332
|
+
|
333
|
+
assert el.checked? == (checked_cond == 'checked')
|
334
|
+
end
|
335
|
+
|
323
336
|
# 5. ========= MISC ACTIONS ===========
|
324
337
|
# 5.1 Pause
|
325
338
|
Then(/^pause for ([^"]*) seconds$/) do |duration|
|
data/lib/cuke_master/version.rb
CHANGED