lib/capybara/spec/session/find_field_spec.rb in capybara-2.3.0 vs lib/capybara/spec/session/find_field_spec.rb in capybara-2.4.0

- old
+ new

@@ -17,9 +17,15 @@ expect do @session.find_field('Does not exist') end.to raise_error(Capybara::ElementNotFound) end + it "should warn if filter option is invalid" do + expect_any_instance_of(Kernel).to receive(:warn). + with('Invalid value nil passed to filter disabled') + @session.find_field('Dog', disabled: nil) + end + it "should be aliased as 'field_labeled' for webrat compatibility" do expect(@session.field_labeled('Dog').value).to eq('dog') expect do @session.field_labeled('Does not exist') end.to raise_error(Capybara::ElementNotFound)