diff options
author | Santiago Pastorino <santiago@wyeworks.com> | 2011-08-31 18:50:38 -0700 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2011-08-31 22:51:37 -0300 |
commit | 3ce3b5b1f1f92d79ee015d246a9f62a725eca5ca (patch) | |
tree | 9497192646574804508139f6aae27d31cb861e9a /railties/test | |
parent | c5a91d02888ae536759780ec6ecb5f7df7241d4b (diff) | |
download | rails-3ce3b5b1f1f92d79ee015d246a9f62a725eca5ca.tar.gz rails-3ce3b5b1f1f92d79ee015d246a9f62a725eca5ca.tar.bz2 rails-3ce3b5b1f1f92d79ee015d246a9f62a725eca5ca.zip |
Merge pull request #2780 from guilleiguaran/assets-pipeline-minor-changes
Assets pipeline: fix in manifest location and remove unused code
Diffstat (limited to 'railties/test')
-rw-r--r-- | railties/test/application/assets_test.rb | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/railties/test/application/assets_test.rb b/railties/test/application/assets_test.rb index ccadf0b2c0..721d082908 100644 --- a/railties/test/application/assets_test.rb +++ b/railties/test/application/assets_test.rb @@ -96,6 +96,19 @@ module ApplicationTests assert_match /application-([0-z]+)\.css/, assets["application.css"] end + test "the manifest file should be saved by default in the same assets folder" do + app_file "app/assets/javascripts/application.js", "alert();" + app_file "config/initializers/manifest.rb", "Rails.application.config.assets.prefix = '/x'" + + capture(:stdout) do + Dir.chdir(app_path){ `bundle exec rake assets:precompile` } + end + + manifest = "#{app_path}/public/x/manifest.yml" + assets = YAML.load_file(manifest) + assert_match /application-([0-z]+)\.js/, assets["application.js"] + end + test "assets do not require any assets group gem when manifest file is present" do app_file "app/assets/javascripts/application.js", "alert();" |