diff --git a/actionpack/test/template/asset_tag_helper_test.rb b/actionpack/test/template/asset_tag_helper_test.rb index 7e40a55..1d81294 100644 --- a/actionpack/test/template/asset_tag_helper_test.rb +++ b/actionpack/test/template/asset_tag_helper_test.rb @@ -65,19 +65,25 @@ class AssetTagHelperTest < ActionView::TestCase JavascriptPathToTag = { %(javascript_path("xmlhr")) => %(/javascripts/xmlhr.js), %(javascript_path("super/xmlhr")) => %(/javascripts/super/xmlhr.js), - %(javascript_path("/super/xmlhr.js")) => %(/super/xmlhr.js) + %(javascript_path("/super/xmlhr.js")) => %(/super/xmlhr.js), + %(javascript_path("http://fake.domain/super/xmlhr")) => %(http://fake.domain/super/xmlhr.js), + %(javascript_path("http://fake.domain/super/xmlhr?callback=fake")) => %(http://fake.domain/super/xmlhr?callback=fake) } PathToJavascriptToTag = { %(path_to_javascript("xmlhr")) => %(/javascripts/xmlhr.js), %(path_to_javascript("super/xmlhr")) => %(/javascripts/super/xmlhr.js), - %(path_to_javascript("/super/xmlhr.js")) => %(/super/xmlhr.js) + %(path_to_javascript("/super/xmlhr.js")) => %(/super/xmlhr.js), + %(path_to_javascript("http://fake.domain/super/xmlhr")) => %(http://fake.domain/super/xmlhr.js), + %(path_to_javascript("http://fake.domain/super/xmlhr?callback=fake")) => %(http://fake.domain/super/xmlhr?callback=fake) } JavascriptIncludeToTag = { %(javascript_include_tag("xmlhr")) => %(), %(javascript_include_tag("xmlhr.js")) => %(), %(javascript_include_tag("xmlhr", :lang => "vbscript")) => %(), + %(javascript_include_tag("http://fake.domain/xmlhr")) => %(), + %(javascript_include_tag("http://fake.domain/xmlhr?callback=fake")) => %(), %(javascript_include_tag("common.javascript", "/elsewhere/cools")) => %(\n), %(javascript_include_tag(:defaults)) => %(\n\n\n\n), %(javascript_include_tag(:all)) => %(\n\n\n\n\n\n\n), @@ -90,14 +96,18 @@ class AssetTagHelperTest < ActionView::TestCase %(stylesheet_path("style")) => %(/stylesheets/style.css), %(stylesheet_path("style.css")) => %(/stylesheets/style.css), %(stylesheet_path('dir/file')) => %(/stylesheets/dir/file.css), - %(stylesheet_path('/dir/file.rcss')) => %(/dir/file.rcss) + %(stylesheet_path('/dir/file.rcss')) => %(/dir/file.rcss), + %(stylesheet_path('http://fake.domain/dir/file')) => %(http://fake.domain/dir/file.css), + %(stylesheet_path('http://fake.domain/dir/file?payload=fake')) => %(http://fake.domain/dir/file?payload=fake) } PathToStyleToTag = { %(path_to_stylesheet("style")) => %(/stylesheets/style.css), %(path_to_stylesheet("style.css")) => %(/stylesheets/style.css), %(path_to_stylesheet('dir/file')) => %(/stylesheets/dir/file.css), - %(path_to_stylesheet('/dir/file.rcss')) => %(/dir/file.rcss) + %(path_to_stylesheet('/dir/file.rcss')) => %(/dir/file.rcss), + %(path_to_stylesheet('http://fake.domain/dir/file')) => %(http://fake.domain/dir/file.css), + %(path_to_stylesheet('http://fake.domain/dir/file?payload=fake')) => %(http://fake.domain/dir/file?payload=fake) } StyleLinkToTag = { @@ -105,6 +115,8 @@ class AssetTagHelperTest < ActionView::TestCase %(stylesheet_link_tag("style.css")) => %(), %(stylesheet_link_tag("/dir/file")) => %(), %(stylesheet_link_tag("dir/file")) => %(), + %(stylesheet_link_tag("http://fake.domain/dir/file")) => %(), + %(stylesheet_link_tag("http://fake.domain/dir/file?payload=fake")) => %(), %(stylesheet_link_tag("style", :media => "all")) => %(), %(stylesheet_link_tag(:all)) => %(\n\n), %(stylesheet_link_tag(:all, :recursive => true)) => %(\n\n\n),