Sha256: d3bcb2edea7c69a1bc25c8ea628376ee5f20900db146c86454cc4a3476131922

Contents?: true

Size: 1.57 KB

Versions: 2

Compression:

Stored size: 1.57 KB

Contents

Then /^the current item should be "([^\"]*)"$/ do |expected_text|
  @page.sel_list_id.should == expected_text
end

Then /^the text should be "([^\"]*)"$/ do |expected_text|
  @text.should == expected_text
end

Then /^I should be on the success page$/ do
  @page.text.should include 'Success'
  @page.title.should == 'Success'
end

Then /^the list items text should be "([^\"]*)"$/ do |expected_text|
  @element.text.should == expected_text
end

When /^I get the first item from the list$/ do
  @element = @list[0]
end

Then /^the table should have "([^\"]*)" rows$/ do |rows|
  @element.rows.should == rows.to_i
end

Then /^each row should contain "([^\"]*)"$/ do |text|
  @element.each do |row|
    row.text.should include text
  end
end

Then /^row "([^\"]*)" should have "([^\"]*)" columns$/ do |row, cols|
  @element[row.to_i - 1].columns.should == cols.to_i
end

Then /^each column should contain "([^\"]*)"$/ do |text|
  row = @element[0]
  row.each do |column|
    column.text.should include text
  end
end

Then /^the list should contain (\d+) items$/ do |items|
  @list.items.should == items.to_i
end

Then /^each item should contain "([^\"]*)"$/ do |text|
  @list.each { |item| item.text.should include text }
end

Then /^option "([^\"]*)" should contain "([^\"]*)"$/ do |opt_num, text|
  @element = @page.send "sel_list_#{@how}_element".to_sym
  @element[opt_num.to_i - 1].text.should == text
end

Then /^each option should contain "([^\"]*)"$/ do |text|
  @element.options.each do |option|
    option.text.should include text
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
meeane-page-object-0.1.10 features/step_definitions/accessor_steps.rb
meeane-page-object-0.1.8 features/step_definitions/accessor_steps.rb