diff options
author | Santiago Pastorino <santiago@wyeworks.com> | 2011-08-01 12:32:17 -0700 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2011-08-01 16:33:27 -0300 |
commit | 6dda2167154c856e8776a192e90118c3b3129b78 (patch) | |
tree | b43a34c8b0c51068e536be42f5532543dd91c0f9 /railties/test/application | |
parent | 6e701e8735df9bf49549e43f001af6a446148b03 (diff) | |
download | rails-6dda2167154c856e8776a192e90118c3b3129b78.tar.gz rails-6dda2167154c856e8776a192e90118c3b3129b78.tar.bz2 rails-6dda2167154c856e8776a192e90118c3b3129b78.zip |
Merge pull request #2324 from zenapsis/3-1-stable
Rails 3.1 throws a Errno::ENOTDIR if files are put in assets directories
Diffstat (limited to 'railties/test/application')
-rw-r--r-- | railties/test/application/assets_test.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/railties/test/application/assets_test.rb b/railties/test/application/assets_test.rb index 7fb930bd99..802b737483 100644 --- a/railties/test/application/assets_test.rb +++ b/railties/test/application/assets_test.rb @@ -109,5 +109,19 @@ module ApplicationTests assert_match "alert()", last_response.body assert_equal nil, last_response.headers["Set-Cookie"] end + + test "files in any assets/ directories are not added to Sprockets" do + %w[app lib vendor].each do |dir| + app_file "#{dir}/assets/#{dir}_test.erb", "testing" + end + + app_file "app/assets/javascripts/demo.js", "alert();" + + require "#{app_path}/config/environment" + + get "/assets/demo.js" + assert_match "alert();", last_response.body + assert_equal 200, last_response.status + end end end |