Sha256: 86be49958c21423fb6bf0744360db9e63e0850e970dec0189966c7993ab3fe54
Contents?: true
Size: 935 Bytes
Versions: 64
Compression:
Stored size: 935 Bytes
Contents
Then /^the form should have inline error messages$/ do page.should have_css(".error") end When /^the "([^"]*)" field should have autocomplete off$/ do |field| field = page.find_field(field) field["autocomplete"].should == "off" end Then /^"([^"]*)" should have the error "([^"]*)"$/ do |field, error| field = page.find_field(field) field.find(:xpath, "following-sibling::p[@class='inline-errors'][contains(text(), '#{error}')]").should_not be_nil end Then /^the "([^"]*)" field(?: within "([^"]*)")? should have nothing in it$/ do |field, selector| with_scope(selector) do field = find_field(field) field_value = (field.tag_name == 'textarea') ? field.text : field.value if field_value.respond_to? :should field_value.should be_nil else assert_nil(field_value) end end end Then /^I there should be a link to the help site$/ do page.should have_css("a[href*='help.example.com']") end
Version data entries
64 entries across 64 versions & 1 rubygems