diff --git a/lib/capybara/driver/rack_test_driver.rb b/lib/capybara/driver/rack_test_driver.rb index 094baf3f..387e3b6b 100644 --- a/lib/capybara/driver/rack_test_driver.rb +++ b/lib/capybara/driver/rack_test_driver.rb @@ -102,7 +102,7 @@ class Capybara::Driver::RackTest if post? driver.submit(node['action'].to_s, params(button)) else - driver.visit(node['action'].to_s + '?' + params(button)) + driver.visit(node['action'].to_s.split('?').first + '?' + params(button)) end end diff --git a/spec/session_spec.rb b/spec/session_spec.rb index 10efa508..c3c0918e 100644 --- a/spec/session_spec.rb +++ b/spec/session_spec.rb @@ -156,9 +156,9 @@ shared_examples_for "session" do it "should serialize and send GET forms" do @session.visit('/form') @session.click_button('med') - #puts @session.body @results = extract_results(@session) @results['middle_name'].should == 'Darren' + @results['foo'].should be_nil end it "should follow redirects" do diff --git a/spec/views/form.erb b/spec/views/form.erb index e04d18b8..d985e6a0 100644 --- a/spec/views/form.erb +++ b/spec/views/form.erb @@ -88,7 +88,7 @@
-