forked from jmoody/briar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtext_field_steps.rb
31 lines (25 loc) · 1.06 KB
/
text_field_steps.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
Then /^I should see the "([^"]*)" text field$/ do |name|
should_see_text_field name
end
Then /^I should not see "([^"]*)" text field$/ do |name|
should_not_see_text_field name
end
Then /^I touch the clear button in the "([^"]*)" text field$/ do |name|
should_see_clear_button_in_text_field name
touch("textField marked:'#{name}' child button")
step_pause
end
Then /^I should see a clear button in the text field in the "([^"]*)" row$/ do |row_id|
query_str = "tableViewCell marked:'#{row_id}' child tableViewCellContentView child textField"
res = query(query_str)
screenshot_and_raise "expected to see text field in '#{row_id}' row" if res.empty?
end
Then /^I touch the clear button in the text field in the "([^"]*)" row$/ do |row_id|
touch_text_field_clear_button_in_row row_id
end
Then(/^I should see "(.*?)" text field with text "(.*?)"$/) do |text_field_id, text|
should_see_text_field_with_text text_field_id, text
end
Then /^I should see "([^"]*)" in the text field "([^"]*)"$/ do |text, text_field|
should_see_text_field_with_text text_field, text
end