Method: RSpec::Matchers#with_text_field

Defined in:
lib/rspec2-rails-views-matchers.rb

#with_text_field(name, value = nil) ⇒ Object



253
254
255
256
257
# File 'lib/rspec2-rails-views-matchers.rb', line 253

def with_text_field name, value=nil
  options = { :with => { :name => name, :type => 'text' } }
  options[:with].merge!(:value => value) if value
  should_have_input(options)
end

Comments