Neeraj Singh
0027b65421
Ensure that while caching a page rails takes into
...
account the resolved mime type for the request
[#6110 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-12-09 16:14:57 +01:00
José Valim
78afe68afb
Merge remote branch 'joshk/redirect_routing'
...
Conflicts:
actionpack/CHANGELOG
actionpack/lib/action_controller/metal/mime_responds.rb
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-12-03 12:27:50 +01:00
Josh Kalderimis
0bda6f1ec6
The redirect routing method now allows for a hash of options which only changes the relevant parts of the url, or an object which responds to call can be supplied so common redirect rules can be easily reused. This commit includes a change where url generation from parts has been moved to AD::Http::URL as a class method.
2010-11-30 16:36:01 +01:00
José Valim
31906eecdf
Fix tests on 1.9.2.
2010-11-28 12:48:50 +01:00
Neeraj Singh
fa2a5ae033
If a user wants json output then try best to render json output. In such cases prefer kind_of(String) over respond_to?(to_str)
...
[#5841 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-24 22:08:36 +01:00
Neeraj Singh
b52a6ba169
clean up test by using unregister method
2010-11-25 04:38:50 +08:00
Neeraj Singh
c6030e8562
Remove the not needed setup and teardown
2010-11-25 04:38:45 +08:00
Josh Kalderimis
2fe43b694f
:subdomain, :domain and :tld_length options can now be used in url_for, allowing for easy manipulation of the host during link generation.
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-23 09:54:42 +01:00
Aaron Patterson
e83d15376d
adding a test for the runner module [ #6027 state:resolved]
2010-11-22 15:57:03 -08:00
Neeraj Singh
cdbbf6fd6b
move the mime registration code to setup so that
...
it could be cleaned up on teardown.
Currently the test code
test/controller/mime_responds_test.rb impacts
test/dispatch/mime_type_test.rb.
dispatch/mime_type_test.rb runs independently fine
but when run as part of rake breaks because of
new mime types registered in
controller/mime_responds_test.rb
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-22 23:06:14 +01:00
Neeraj Singh
eb6ccc9953
do not assume that there is no space between
...
leading */* and comma
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-22 23:06:12 +01:00
Neeraj Singh
f5fba917f8
failing test for #6022
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-22 23:06:12 +01:00
Neeraj Singh
61950a4b05
current code ignores http header "Accept" if it
...
has ....,*/* .
It is possible to a device to send
request such that */* appear at the beginning of the
"Accept" header. This patch ensures that "Accept" header
is ignored for such cases too.
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-22 23:06:12 +01:00
Xavier Noria
799a6fa047
realigns a series of hash arrows
2010-11-21 10:25:23 +01:00
Santiago Pastorino
52b71c01fd
Revert "Quick fix for not escaping []s (not ideal)"
...
According to http://www.ietf.org/rfc/rfc2616.txt and
http://tools.ietf.org/rfc/rfc3986.txt [ and ] are reserved characters
and should be escaped using "%" HEX HEX
This reverts commit 856d2fd874 and
1ee9b40b18a0bed5bb10a0785f7e2730bac983f6..
2010-11-18 23:31:00 -02:00
Neeraj Singh
fe2f168d40
fix warning during test execution
...
[#5997 state:resolved]
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com >
2010-11-17 20:19:07 -02:00
Carl Lerche
401c1835af
Anchors should be allowed on constraints that are not on path segments
2010-11-16 21:46:15 -08:00
Aaron Patterson
0be181bfa0
make sure we are only doing sanity checking against regular expressions
2010-11-15 13:37:27 -08:00
Marcelo Giorgi
2bb1c202b4
Make after_filter halt when before_filter renders or redirects [ #5648 state:resolved]
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-11-11 17:05:07 +01:00
Jan Maurits Faber
f04ec6a227
Added support for Erubis <%== tag
...
<%== x %> is syntactic sugar for <%= raw(x) %>
Signed-off-by: Michael Koziarski <michael@koziarski.com >
[#5918 status:committed]
2010-11-08 09:55:55 +13:00
Santiago Pastorino
2382667955
Fix problems trying to functional test AC::Metal controllers
...
[#5393 state:committed]
2010-11-06 21:15:03 -02:00
Chris Eppstein
b1667c7c2c
Correctly handle the case of an API response that returns a hash by treating a single hash argument as the resource instead of as options.
2010-11-06 06:56:36 +08:00
Andrew White
f7573175de
Reset assert_template instance variables between requests [ #5832 state:resolved]
2010-10-18 09:57:51 +01:00
Xavier Noria
21ff8849bb
in regexps, the dot in a character class is not a metacharacter
2010-10-15 16:31:00 +02:00
José Valim
01ab6f961b
Remove :cache => true on lookup templates initialization.
2010-10-14 09:47:49 +02:00
José Valim
37d78028b2
render :once should consider the current controller prefix.
2010-10-14 09:27:18 +02:00
Szymon Nowak
0d33332571
Return a valid empty JSON on successful PUT and DELETE requests. [ #5199 state:resolved]
...
Signed-off-by: José Valim <jose.valim@gmail.com >
2010-10-12 00:56:07 +02:00
José Valim
682368d4ba
Use identifiers for template equality.
2010-10-10 23:12:22 +02:00
José Valim
940b57789f
Add support to render :once.
...
This will be used internally by sprockets to ensure requires are executed just once.
2010-10-10 12:43:26 +02:00
wycats
8cb2cfbf71
Fix a few bugs when trying to use Head standalone
2010-10-10 00:54:11 -07:00
José Valim
c7408a0e40
Deprecate old template handler API. Remove old handlers.
2010-10-10 01:14:50 +02:00
José Valim
c7760809bf
Allow cache to be temporarily disabled through lookup_context.
2010-10-07 21:31:31 +02:00
José Valim
c563f10f3e
render :template => 'foo/bar.json' now works as it should.
2010-10-07 21:31:31 +02:00
Aaron Patterson
5769636663
fixing a few test warnings
2010-10-04 19:32:49 -07:00
Aaron Patterson
18a7b767e8
moving fake model to the correct file
2010-10-03 14:40:06 -07:00
José Valim
74dd8a3681
Move ETag and ConditionalGet logic from AD::Response to the middleware stack.
2010-10-03 21:25:22 +02:00
Aaron Patterson
3eb7f9adee
removing more duplicate code. :'(
2010-10-01 18:09:37 -07:00
Aaron Patterson
50cf5c11a1
fixing warnings with regexps on assert_match
2010-10-01 18:07:19 -07:00
Aaron Patterson
ffbcb84c21
removing more duplicate code
2010-10-01 18:05:59 -07:00
Aaron Patterson
44f85678e9
delete repeated code
2010-10-01 18:01:34 -07:00
Aaron Patterson
dfa331ae15
use a method that actually exists
2010-10-01 17:54:50 -07:00
Aaron Patterson
1c0be7baac
fixing space error
2010-09-29 11:47:54 -07:00
Emilio Tagua
6371e5b99f
We can't assign @view_context_class here, define super() in test instead if we want to avoid warnings.
2010-09-29 14:35:24 -03:00
Emilio Tagua
c37800aae1
_ is not a valid scheme name character, \w includes it and also is redundant with \d.
...
'The scheme name consists of a letter followed by any combination of letters, digits, and the plus ("+"), period ("."), or hyphen ("-") characters; and is terminated by a colon (":").'
2010-09-29 12:55:43 -03:00
Emilio Tagua
bc0e7f4e37
Test correct method behaviour.
2010-09-29 12:42:51 -03:00
José Valim
0bbf9029e8
Merge remote branch 'miloops/warnings'
2010-09-29 10:04:42 +02:00
Emilio Tagua
d5bb640eb0
Remove methods to avoid warnings.
2010-09-28 18:40:38 -03:00
Emilio Tagua
34fc109549
Redefine duplicated test name.
2010-09-28 18:36:45 -03:00
Emilio Tagua
523f98099d
Remove more warnings on AP.
2010-09-28 18:01:48 -03:00
Emilio Tagua
ad2c21089e
Define @title to avoid warnings.
2010-09-28 17:44:26 -03:00