From 64268a0b06d32567c6e88b7293f332b79e10414b Mon Sep 17 00:00:00 2001 From: Matthew Rudy Jacobs Date: Wed, 5 Aug 2009 15:58:55 +0100 Subject: Make sure javascript_include_tag/stylesheet_link_tag does not append ".js" or ".css" onto external urls [#1664 state:resolved] Signed-off-by: Pratik Naik --- actionpack/test/template/asset_tag_helper_test.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'actionpack/test') diff --git a/actionpack/test/template/asset_tag_helper_test.rb b/actionpack/test/template/asset_tag_helper_test.rb index 08963946ab..28f9d48671 100644 --- a/actionpack/test/template/asset_tag_helper_test.rb +++ b/actionpack/test/template/asset_tag_helper_test.rb @@ -83,7 +83,10 @@ class AssetTagHelperTest < ActionView::TestCase %(javascript_include_tag(:all)) => %(\n\n\n\n\n\n\n), %(javascript_include_tag(:all, :recursive => true)) => %(\n\n\n\n\n\n\n\n), %(javascript_include_tag(:defaults, "bank")) => %(\n\n\n\n\n), - %(javascript_include_tag("bank", :defaults)) => %(\n\n\n\n\n) + %(javascript_include_tag("bank", :defaults)) => %(\n\n\n\n\n), + + %(javascript_include_tag("http://example.com/all")) => %(), + %(javascript_include_tag("http://example.com/all.js")) => %(), } StylePathToTag = { @@ -111,7 +114,8 @@ class AssetTagHelperTest < ActionView::TestCase %(stylesheet_link_tag(:all, :media => "all")) => %(\n\n), %(stylesheet_link_tag("random.styles", "/elsewhere/file")) => %(\n), - %(stylesheet_link_tag("http://www.example.com/styles/style")) => %() + %(stylesheet_link_tag("http://www.example.com/styles/style")) => %(), + %(stylesheet_link_tag("http://www.example.com/styles/style.css")) => %(), } ImagePathToTag = { -- cgit v1.2.3