Hongli Lai (Phusion)
bc2c4a4595
Cleanup application after #close has been called on the Rack response body, not when AC::Reload#call is done.
...
The Rack body might lazily evaluate its output, which is for example the case
if one calls 'render :text => lambda { ... }'. The code which lazily evaluates
the output might use other application classes. So we will want to defer
cleanup until the Rack request is completely finished.
Signed-off-by: Michael Koziarski <michael@koziarski.com >
2009-07-08 13:46:10 +12:00
Jesús García Sáez
6673001a5e
Allow symbols on routes declaration (:controller and :action values) [ #2828 state:resolved]
...
Signed-off-by: Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com >
2009-07-02 12:19:38 -07:00
Yehuda Katz + Carl Lerche
e10305f0f4
Accept Symbol for contoller name [ #2855 state:resolved]
...
Signed-off-by: Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com >
2009-07-01 11:51:09 -07:00
Michael Koziarski
9407f6e9a4
Make filter_parameters work correctly with array parameters.
...
Conflicts:
actionpack/lib/action_controller/base/filter_parameter_logging.rb
2009-06-27 13:11:01 +12:00
Joshua Peek
6720b25b2d
send_data should set Content-Length as a string
2009-06-25 14:44:09 -05:00
Steven Luscher
d63fab344f
Fixes #2439 . ActionController::Integration::Session no longer mangles multiparameter attribute params when processing multipart requests.
...
Signed-off-by: Michael Koziarski <michael@koziarski.com >
2009-06-09 20:14:01 +12:00
nate
056ddbdcfb
A test to show that http_authentication needs to fail authentication if the password procedure returns nil. Also includes a fix to validate_digest_response to fail validation if the password procedure returns nil.
...
Signed-off-by: Michael Koziarski <michael@koziarski.com >
2009-06-09 19:47:16 +12:00
Jeremy Kemper
91fbdfd5b3
Failsafe doesn't return bare String body
2009-06-08 20:35:52 -07:00
Joshua Peek
c73cf7d2c0
Revert "Only save the session if we're actually writing to it [ #2703 state:resolved]"
...
This reverts commit 14edaa104d .
2009-05-30 09:36:32 -05:00
Johan Sörensen
14edaa104d
Only save the session if we're actually writing to it [ #2703 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-05-28 09:32:16 -05:00
Johan Sörensen
dc94c09503
The FlashHash and friends causes a lot of needless session storing, when we know for a fact that there's no content in the flash. By not storing the empty hash in the session we save a lot of communication with the various session backends, while still keeping the same interface to the flash. [ #2703 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-05-28 09:22:35 -05:00
Hongli Lai (Phusion)
34a1ed0df8
Make the Failsafe middleware attempt to render 500.html during failsafe response rendering. Also make the default static failsafe response more friendly, in case 500.html rendering fails. [ #2715 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-05-27 14:59:11 -05:00
Pratik Naik
dbb0258279
Ensure HTTP Digest auth uses appropriate HTTP method [ #2490 state:resolved] [Steve Madsen]
2009-05-18 17:00:29 +02:00
rick
d052e9fb58
Add pluggable JSON backends with support for the JSON gem.
...
Example: ActiveSupport::JSON.backend = "JSONGem"
All internal Rails JSON encoding is now handled by
ActiveSupport::JSON.encode(). Use of #to_json is not recommended, as it
may clash with other libraries that overwrite it. However, you can
recover Rails specific functionality
if you really want to use #to_json.
gem 'json'
ActiveSupport::JSON.backend = "JSONGem"
class ActiveRecord::Base
alias to_json rails_to_json
end
2009-05-17 18:40:38 -07:00
Mike Breen
f383a4aa33
Allow assert_template to take a symbol [ #2011 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-05-17 19:40:18 +02:00
Joshua Peek
f7cb7fce4c
Sweeper does not belong in Sweeping module
2009-05-14 16:47:24 -05:00
Joshua Peek
7f1f16c01f
Deprecate assert_redirect_to's partial hash matching. This will be fully removed in 3.0.
2009-05-04 20:24:49 -05:00
Ruy Asan
17e712d3a3
Added routing test for irregular ID requirements and custom member action.
...
[#2595 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net >
2009-05-01 15:02:51 -07:00
John F. Douthat
d1d1894c2f
Fix action-cached exception responses.
...
Methods raising ActiveRecord::RecordNotFound were returning 404 on first request and 200 OK with blank body on subsequent requests.
[#2533 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net >
2009-04-30 16:48:07 -07:00
Jeremy Kemper
7c4b325e0a
Fix render :json => nil [ #2589 state:resolved]
2009-04-30 16:47:42 -07:00
Joshua Peek
61a1456937
Remove RewindableInput middleware since all input MUST be rewindable according to a recent change in the Rack 1.0 SPEC
2009-04-25 14:05:58 -05:00
Joshua Peek
16f36b6171
Remove vendored version of Rack
2009-04-25 13:59:26 -05:00
Mislav Marohnić
35c5727ace
Always buffer rack.input if it is not rewindable
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-04-17 21:54:09 -05:00
Mislav Marohnić
878aec9d95
Improve rewindable input test coverage so tests fail when you remove the middleware
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-04-17 19:35:25 -05:00
Doug McInnes
dc69d9308a
Fix for TestResponse.cookies returning cookies unescaped [ #1867 state:resolved]
...
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com >
2009-04-07 13:22:21 -05:00
Kenny Ortmann
ace154d067
added tests for session options being defaulted correctly to rack defaults [ #2403 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-04-07 11:08:04 -05:00
Ryan Angilly
651611999d
adding session_options initialization and test [ #2303 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-03-24 10:53:29 -05:00
David Dollar
dace54b2e9
Updates tests to cause the tests for the Request class not to proxy through a fake TestRequest object [ #2278 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-03-24 10:53:14 -05:00
Peter Marklund
daffa5cbdd
Reset request_parameters in TestRequest#recycle! to avoid multiple posts clobbering each other [ #2271 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-03-24 10:53:07 -05:00
Joshua Peek
c91912700d
just kill brittle test
2009-03-24 10:52:49 -05:00
Joshua Peek
4185a4a5f5
update rack fixture to be ruby 1.9 compat
2009-03-15 23:48:07 -05:00
Joshua Peek
0706de4301
Better error message to try to figure out why the CI build is failing
2009-03-15 23:41:47 -05:00
Joshua Peek
d0e5417861
update rack fixture to be ruby 1.9 compat
2009-03-15 23:25:12 -05:00
Joshua Peek
367049cae6
Fix brittle Time.now mock
2009-03-15 23:17:31 -05:00
misfo
7706b57034
allowed render :file to take Pathnames [ #2220 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-03-14 10:42:02 -05:00
Mike Gunderloy
07710fd3e0
Fix requirements for additional member/collection routes [ #2054 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-03-14 10:06:00 -05:00
Joshua Peek
5b025a1d11
Revert 5b7527ca "Failing test for routes with member & requirement" [ #2054 state:wontfix]
2009-03-13 17:13:18 -05:00
Joshua Peek
eced3d8c55
Update rack to fix multipart uploads with an empty file [ #1945 state:resolved]
2009-03-13 17:13:10 -05:00
Mike Gunderloy
d771e7d17f
Handle irregular plurals in polymorphic_urls [ #2212 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-12 17:02:07 +00:00
Donald Parish
be7b64b35a
Support MD5 passwords for Digest auth and use session_options[:secret] in nonce [ #2209 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-12 13:24:54 +00:00
Mislav Marohnić
fa45540cdb
Ensure correct content type is declared after cache hits on actions with string cache keys [ #1585 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-10 23:31:19 +00:00
Joshua Peek
224a534400
reset_session should force a new session id to be generated [ #2173 ]
2009-03-09 22:46:03 -05:00
Andrew Bloom
90dba00822
Ensure blank path_prefix works as expected [ #2122 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-09 15:27:13 +00:00
Jeremy Kemper
1c36172c13
Ruby 1.9 compat: rename deprecated assert_raises to assert_raise.
...
[#1617 state:resolved]
2009-03-08 13:11:58 -07:00
Mike Gunderloy
5e0f6214d2
Support OPTIONS verb in route conditions [ #1727 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-08 12:37:17 +00:00
Tom Stuart
5c87e9addd
Ensure shallow routes respects namespace [ #1356 state:resolved]
...
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-07 22:50:58 +00:00
Joshua Peek
ea8488caef
Fixed simplified render with nested models [ #2042 state:resolved]
2009-03-07 14:05:18 -06:00
Matt Jones
87e8b16246
fix HTML fallback for explicit templates [ #2052 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2009-03-07 13:32:46 -06:00
Pratik Naik
272c2d2e9c
Ensure assert_select works with XML namespaced attributes [ #1547 state:resolved] [Jon Yurek]
2009-03-07 16:13:34 +00:00
Johan Sørensen
c071123b3e
Ensure expires_in without a :public key sets the Cache-Control header to private. [ #2095 state:resolved]
...
This fixes a regression introduced in f2a32bd0 , which wasn't exposed due to two
test methods having the same name.
Signed-off-by: Pratik Naik <pratiknaik@gmail.com >
2009-03-07 12:18:10 +00:00