diff options
author | Yehuda Katz <wycats@gmail.com> | 2009-10-14 11:59:00 -0700 |
---|---|---|
committer | Yehuda Katz <wycats@gmail.com> | 2009-10-14 13:36:41 -0700 |
commit | a41c6c35cadf75bfd4bf0a17113ae37d628896e8 (patch) | |
tree | 2fd868ac1a5a4674f5a6960c931b96d6cbda48f4 /actionpack/test/template/asset_tag_helper_test.rb | |
parent | a8dc9fd27b845193fd209a249e084f993a10c19d (diff) | |
download | rails-a41c6c35cadf75bfd4bf0a17113ae37d628896e8.tar.gz rails-a41c6c35cadf75bfd4bf0a17113ae37d628896e8.tar.bz2 rails-a41c6c35cadf75bfd4bf0a17113ae37d628896e8.zip |
Start adding configuration to ActionView instead of using constants.
By using config rather than hardcoded constants, we can evolve the
configuration system over time (we'd just need to update the config
method with more robust capabilities and all consumers would get
the capabilities with no code changes)
Diffstat (limited to 'actionpack/test/template/asset_tag_helper_test.rb')
-rw-r--r-- | actionpack/test/template/asset_tag_helper_test.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/actionpack/test/template/asset_tag_helper_test.rb b/actionpack/test/template/asset_tag_helper_test.rb index d94135b04b..57802ebf42 100644 --- a/actionpack/test/template/asset_tag_helper_test.rb +++ b/actionpack/test/template/asset_tag_helper_test.rb @@ -3,6 +3,13 @@ require 'abstract_unit' class AssetTagHelperTest < ActionView::TestCase tests ActionView::Helpers::AssetTagHelper + DEFAULT_CONFIG = ActionView::DEFAULT_CONFIG.merge( + :assets_dir => File.dirname(__FILE__) + "/../fixtures/public", + :javascripts_dir => File.dirname(__FILE__) + "/../fixtures/public/javascripts", + :stylesheets_dir => File.dirname(__FILE__) + "/../fixtures/public/stylesheets") + + include ActiveSupport::Configurable + def setup super silence_warnings do @@ -872,6 +879,9 @@ end class AssetTagHelperNonVhostTest < ActionView::TestCase tests ActionView::Helpers::AssetTagHelper + DEFAULT_CONFIG = ActionView::DEFAULT_CONFIG + include ActiveSupport::Configurable + def setup super ActionController::Base.relative_url_root = "/collaboration/hieraki" |