Commit Graph

43 Commits

Author SHA1 Message Date
Jeremy Kemper
bceec4c3c3 / is allowed in URI fragments 2011-10-13 21:41:30 -07:00
Piotr Sarnacki
b3eb26a161 Removed deprecated RouteSet API, still many tests fail 2010-09-05 13:44:36 +02:00
Joshua Peek
cdf8c35ffd Consistent routing language 2010-03-30 14:05:42 -05:00
Joshua Peek
4d2470f7da RouteSet#rewrite => url_for 2010-03-09 21:00:24 -06:00
Joshua Peek
7db80f87e9 Move AC::UrlRewriter onto route set 2010-03-09 20:50:35 -06:00
wycats
de79525d04 Get rid of the instance-level URL rewriter 2010-03-09 10:20:56 -08:00
Carlhuda
226dfc2681 WIP: Remove the global router 2010-02-25 17:53:00 -08:00
José Valim
f564f947d9 Remove duplicated url_for code and move methods shared between ActionMailer and ActionController up to AbstractController. 2010-01-07 15:31:50 +01:00
José Valim
bd729344a7 Remove deprecated formatted named routes 2010-01-04 23:05:27 +01:00
Joshua Peek
9fbde11b8b More test porting 2009-12-08 17:41:00 -06:00
Joshua Peek
2be5e088d2 Use new routing dsl in tests 2009-12-08 16:52:26 -06:00
Joshua Peek
a5c82a9dfb Start rewriting some internal tests to use the new routing dsl 2009-10-20 16:03:55 -05:00
Joshua Peek
cc0103fe83 Fix brittle query string comparisons 2009-10-17 19:18:18 -05:00
Joshua Peek
2ae84e04aa Add fake controllers for url rewriter tests 2009-09-06 23:02:55 -05:00
Jeffrey Hardy
05b529ca57 UrlRewriter#rewrite_url should call #to_param on the value given in :anchor option, just as #url_for does
[#2746 state:committed]

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
2009-08-26 14:11:26 -07:00
Joshua Peek
24ad9ae3d2 Cleanup route reloading in tests. Prefer with_routing over using ActionController::Routing::Routes directly 2009-08-16 21:14:26 -05:00
Joshua Peek
734e903af5 Deprecate router generation "best match" sorting 2009-08-09 22:53:16 -05: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
Nathan de Vries
32eeb3e521 Ensure that when UrlWriter is included in multiple classes, the default_url_options of one don't affect the other. [#1277 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
2009-01-28 19:31:48 +00:00
David Heinemeier Hansson
7d8f9ef051 Fix routing test and add changelog note about draw no longer clearing the route set 2008-11-26 20:26:55 +01:00
Aaron Batalion
fef6c32afe Added optimal formatted routes to rails, deprecating the formatted_* methods, and reducing routes creation by 50% [#1359 state:committed]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
2008-11-26 10:52:05 +01:00
Jeremy Kemper
c82e8e1f48 Move controller assertions from base TestCase to AC:: and AV::TestCase 2008-11-07 15:42:34 -05:00
Joshua Peek
a87462afcb AbstractRequest.relative_url_root is no longer automatically configured by a HTTP header. It can now be set in your configuration environment with config.action_controller.relative_url_root 2008-07-24 13:41:51 -05:00
Michael Koziarski
db4f421b0b Add :trailing_slash option to UrlWriter. Closes #9117 [juanjo.bazan]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8892 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-02-18 00:42:06 +00:00
Jeremy Kemper
59f222dbf7 UrlWriter respects relative_url_root. Closes #10748.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8616 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-10 02:51:09 +00:00
Jeremy Kemper
9d755f1983 require abstract_unit directly since test is in load path
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8564 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-05 13:32:06 +00:00
Jeremy Kemper
d9f3c435f9 Fix url_for, redirect_to, etc. with :controller => :symbol instead of 'string'. Closes #8562, #9525.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7776 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-10-07 19:12:02 +00:00
Michael Koziarski
7cb26b5d2d Disable optimisation code for UrlWriter as request.host doesn't make sense there.
Don't try to use the .to_query method when the route has no dynamic segments.


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7501 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-09-17 09:30:18 +00:00
Michael Koziarski
5476a6a6c7 Make :trailing_slash work with query parameters for url_for. Closes #4004 [nov]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7186 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-07-14 09:28:56 +00:00
Jeremy Kemper
17927cbddc Improve UrlRewriter tests. Improve helper test coverage. Closes #7207, #7208, #7212.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7013 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-06-13 01:34:16 +00:00
Nicholas Seckar
5a3bb880db Update UrlWriter to accept :anchor parameter. Closes #6771.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6648 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-05-02 04:40:33 +00:00
Jeremy Kemper
8e01143854 Adjust test for unsorted Array#to_query. References #7756.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6380 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-03-11 13:29:40 +00:00
Jeremy Kemper
e17df19b86 Allow array and hash query parameters. Array route parameters are converted/to/a/path as before. References #6765, #7462. Closes #7047.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6343 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-03-06 07:47:23 +00:00
David Heinemeier Hansson
4568c1d744 Added URL escaping of user and password when used through the UrlWriter
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6314 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-03-04 20:10:51 +00:00
David Heinemeier Hansson
bf6d4cede7 Added user/password options for url_for to add http authentication in a URL [DHH]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6302 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-03-03 22:19:54 +00:00
David Heinemeier Hansson
b8cd80550f Added :port and :host handling to UrlRewriter (which unified url_for usage, regardless of whether it's called in view or controller) #7616 [alancfrancis]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6235 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-02-25 20:22:09 +00:00
Nicholas Seckar
35ec1c928f Fix doubly appearing parameters due to string and symbol mixups. Closes #2551.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6053 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2007-01-28 05:29:32 +00:00
Nicholas Seckar
d1529a71d1 Update Routing to complain when :controller is not specified by a route. Closes #6669.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5607 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-11-22 16:31:00 +00:00
Nicholas Seckar
00685ad8fd Update UrlWriter to support :only_path.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5054 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-09-06 22:21:36 +00:00
David Heinemeier Hansson
4bd444c1fe More deprecation fun
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4943 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-09-03 22:35:31 +00:00
Nicholas Seckar
3b1972a896 Add UrlWriter to allow writing urls from Mailers and scripts.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4814 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-08-24 06:15:01 +00:00
Jamis Buck
b20c575ac0 New routes implementation. Simpler, faster, easier to understand. The published API for config/routes.rb is unchanged, but nearly everything else is different, so expect breakage in plugins and libs that try to fiddle with routes.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4394 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2006-06-01 15:42:08 +00:00
David Heinemeier Hansson
c1505e3e2b Included UrlRewriter tests in rake run and made them not depend on Hash order
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2244 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2005-09-15 05:24:29 +00:00