Commit Graph

29 Commits

Author SHA1 Message Date
Thomas Walpole 8d7e432a3b test for issue of cookie not getting set in rack test when first request has a blank path 2013-05-15 13:12:30 -07:00
Jarl Friis 3e2d7c2114 Support for multiple file upload.
Squashed commit of the following:

commit fb88141863
Author: Jarl Friis <jarl@softace.dk>
Date:   Mon Sep 3 22:06:07 2012 +0200

    Improved implementation. Removing need for YAML. Extending the driver API to take an Array when 'multiple' attribute is present.

commit 977f1c50c2
Author: Jarl Friis <jarl@softace.dk>
Date:   Mon Sep 3 11:56:04 2012 +0200

    Changing decision criteria to support 1.8.7

commit b217deef4a
Author: Jarl Friis <jarl@softace.dk>
Date:   Mon Sep 3 10:38:16 2012 +0200

    Support for 'multiple' attribute in input tags, see https://github.com/jnicklas/capybara/issues/778

commit 155b9fcf79
Author: Jarl Friis <jarl@softace.dk>
Date:   Mon Sep 3 10:33:00 2012 +0200

    Test that demonstrates lack of support for 'multiple' attribute in input tags, see https://github.com/jnicklas/capybara/issues/778

Conflicts:

	lib/capybara/node/actions.rb
	lib/capybara/selenium/node.rb
	lib/capybara/spec/session/attach_file_spec.rb
2012-09-17 20:04:00 +02:00
Jonas Nicklas 6f145fb069 Raise errors in main thread when error in application occurs, closes #660 2012-07-13 14:57:43 +02:00
Jo Liss 21d0b25dba Rack::Test now does not send a referer when calling `visit` multiple times 2012-02-01 01:12:38 +01:00
Jo Liss 0209a2c721 Revert "Use method="post"."
This reverts commit 3f2e0288ca.
2012-01-12 18:30:21 +01:00
Jon Leighton 3f2e0288ca Use method="post".
WebKit will append a '?' to the URL when submitting a form via GET, even
if there is no actual form data. (Firefox does not.) This causes a couple
of tests to fail for the Poltergeist driver, because the tests do not
expect there to be a '?'. Presumably it would also affect
capybara-webkit.

I am not sure which behaviour is 'correct' but it would seem a bad idea
to mess with the URL that the browser is actually providing, so changing
to test like this just allows the results to be consistent.
2012-01-12 16:26:25 +00:00
Jo Liss 7b5682e272 Add more referer tests
This includes a pending test "should send no referer when visiting a
second page", which does not pass on Rack::Test right now.
2012-01-10 18:09:06 +01:00
Jo Liss d1ff724e78 Merge pull request #603 from robvandijk/master
Referer should point to original referer after a redirect
2012-01-10 08:39:59 -08:00
Rob van Dijk 757c135b8e Moved test to shared_example_for in driver, included test both for rack_test and selenium 2012-01-10 17:08:22 +01:00
Jo Liss 6446d74733 Add conspicuous pointer at top of spec/test_app.rb to help contributors 2012-01-10 01:45:11 +01:00
Rob van Dijk bf1637eb6d Use the referer of the last request when redirecting 2012-01-08 22:45:47 +01:00
Jo Liss 74d01a7b2b Eliminate dependency on Heroku apps to make specs less brittle
Fold all current_host specs into common current{_url,_host,_path} specs,
since current_host simply calls current_url. Since current_host omits
the port, differentiating between different servers on localhost is
impossible without the help of current_url.

Two examples are pending now, since Rack::Test ignores ports when
changing hosts.
2012-01-04 19:04:09 +01:00
Jonas Nicklas and Kim Burgestrand 0188693ced Added option for rack-test driver to disable data method hack closes #184 2011-08-30 11:20:29 +02:00
Jonas Nicklas and Nicklas Ramhöj 39eac9af37 Fix paths relative to root path in rack-test, closes #454 2011-08-30 10:54:20 +02:00
Jonas Nicklas and Nicklas Ramhöj 33b1a27c32 Preserve headers on redirects, closes #464 2011-08-30 10:19:52 +02:00
Matt Colyer 3111e80145 Add a failing test. 2011-07-18 12:08:55 -07:00
John Barton (joho) 8834050049 Actually properly handling relative URLs for forms
(Where I subtly misunderstood how URIs work)
2011-05-22 18:37:02 +10:00
John Barton (joho) 4d4eebe573 Fix problem where capybara can't post to relative urls in form actions. 2011-05-22 18:13:40 +10:00
Jonas Nicklas 3e5d923b45 don't use request.domain as it's not always available 2011-04-02 16:58:13 +02:00
Jonas Nicklas 29319c0546 Nail down behaviour of rack-test and hosts 2011-03-25 09:16:28 +00:00
Jonas Nicklas and Nicklas Ramhöj 021b87f6ba Selenium driver automatically waits for AJAX requests to finish 2011-02-22 15:53:43 +01:00
Jonas Nicklas 3cd365819b Make Capybara::Driver::RackTest#reset! more comprehensive
So that it resets request, responses and headers as well as cookies
2011-01-19 12:39:15 +00:00
Jonas Nicklas 380f3d7a08 Merge branch 'master' of https://github.com/ryankinderman/capybara into ryankinderman-master 2010-12-22 15:46:19 +01:00
Jonas Nicklas c20a00c694 Testapps self contained running uses WEBrick
There's really no point in using Mongrel
2010-12-17 09:19:47 +01:00
Jonas Nicklas 29898295dc Fixes issue with multipart forms being submitted as x-www-form-urlencoded when they contain an empty file field 2010-12-06 01:35:07 -06:00
Philip Arndt 4cfe882c98 Turns out we don't have to exclude @multiple after all but merely @type='file'. Now includes specs that pass with this change and fail without it. 2010-11-11 11:43:58 +13:00
Myron Marston 5b72525a96 Detect infinite redirection (i.e. more than 5 redirects).
This originally worked with a timeout. Jonas fixed it so that it follows 5 redirects, but the infinite redirect error was not raised.
2010-06-29 14:11:24 -07:00
Carlos Antonio da Silva 5ad348d776 Add cleanup method to clear cookies for Celerity/Culerity and RackTest, with tests for Selenium included 2010-06-24 10:51:44 -03:00
Jonas Nicklas cf1aa4d073 Moved shared specs into lib directory
This way, implementations of other drivers can
use the specs to verify that they are working
correctly.
2010-04-09 16:41:35 +02:00