From ba0fd2d6980e18d2cc6efa0c48e932e5ddea3946 Mon Sep 17 00:00:00 2001 From: Sven Fuchs Date: Tue, 25 Nov 2008 20:09:12 +0100 Subject: [PATCH] test that #compute_public_path caching allows to return different results for different given sources --- actionpack/test/template/asset_tag_helper_test.rb | 14 ++++++++++++++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/actionpack/test/template/asset_tag_helper_test.rb b/actionpack/test/template/asset_tag_helper_test.rb index 2c0caef..504c9d7 100644 --- a/actionpack/test/template/asset_tag_helper_test.rb +++ b/actionpack/test/template/asset_tag_helper_test.rb @@ -655,3 +655,17 @@ class AssetTagHelperNonVhostTest < ActionView::TestCase end end + +class AssetTagHelperImplementationTest < ActionView::TestCase + tests ActionView::Helpers::AssetTagHelper + + def teardown + AssetTag::Cache.clear + end + + def test_compute_public_path_caching_should_allow_returning_different_results_for_different_given_sources + tag = ImageTag.new nil, nil, nil + assert_not_equal tag.send(:compute_public_path, 'path/to/foo'), + tag.send(:compute_public_path, 'path/to/bar') + end +end \ No newline at end of file -- 1.5.3.7