aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template/asset_tag_helper_test.rb
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2007-09-24 19:47:45 +0000
committerJeremy Kemper <jeremy@bitsweat.net>2007-09-24 19:47:45 +0000
commit40f9fd39f6b471cb35b551b456f2c22d52f1b825 (patch)
treefe2256c63d0dc00ed0d2fd6a8bc33e0e21e18d16 /actionpack/test/template/asset_tag_helper_test.rb
parent605aadb3cdba9f469e88c39c0cad7448d59a9f0c (diff)
downloadrails-40f9fd39f6b471cb35b551b456f2c22d52f1b825.tar.gz
rails-40f9fd39f6b471cb35b551b456f2c22d52f1b825.tar.bz2
rails-40f9fd39f6b471cb35b551b456f2c22d52f1b825.zip
Include asset host in public path cache key. Clear cache between asset tag tests.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7617 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/test/template/asset_tag_helper_test.rb')
-rw-r--r--actionpack/test/template/asset_tag_helper_test.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/actionpack/test/template/asset_tag_helper_test.rb b/actionpack/test/template/asset_tag_helper_test.rb
index 7708154048..1463ee1dce 100644
--- a/actionpack/test/template/asset_tag_helper_test.rb
+++ b/actionpack/test/template/asset_tag_helper_test.rb
@@ -33,11 +33,14 @@ class AssetTagHelperTest < Test::Unit::TestCase
@request = Class.new do
def relative_url_root() "" end
+ def protocol() 'http://' end
end.new
@controller.request = @request
ActionView::Helpers::AssetTagHelper::reset_javascript_include_default
+
+ ActionView::Base.computed_public_paths.clear
end
def teardown
@@ -128,6 +131,8 @@ class AssetTagHelperTest < Test::Unit::TestCase
ENV["RAILS_ASSET_ID"] = ""
JavascriptIncludeToTag.each { |method, tag| assert_dom_equal(tag, eval(method)) }
+ ActionView::Base.computed_public_paths.clear
+
ENV["RAILS_ASSET_ID"] = "1"
assert_dom_equal(%(<script src="/javascripts/prototype.js?1" type="text/javascript"></script>\n<script src="/javascripts/effects.js?1" type="text/javascript"></script>\n<script src="/javascripts/dragdrop.js?1" type="text/javascript"></script>\n<script src="/javascripts/controls.js?1" type="text/javascript"></script>\n<script src="/javascripts/application.js?1" type="text/javascript"></script>), javascript_include_tag(:defaults))
end