diff options
author | Yves Senn <yves.senn@gmail.com> | 2015-01-28 12:31:25 +0100 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2015-01-28 12:31:25 +0100 |
commit | 58047ebdf3da86a8ed17cb269c5d4d944d1c2d88 (patch) | |
tree | c483c37f26a98e4bad4671869067bf6f07216cc6 /railties | |
parent | 71a84206ab4d3488ac0d522a7375efc67301aae5 (diff) | |
parent | d28e5b94a7ef90cd9e569f5c12485814fcadd70a (diff) | |
download | rails-58047ebdf3da86a8ed17cb269c5d4d944d1c2d88.tar.gz rails-58047ebdf3da86a8ed17cb269c5d4d944d1c2d88.tar.bz2 rails-58047ebdf3da86a8ed17cb269c5d4d944d1c2d88.zip |
Merge pull request #18658 from senny/file_fixtures
Add `ActiveSupport::Testing::FileFixtures`.
Diffstat (limited to 'railties')
-rw-r--r-- | railties/lib/rails/generators/rails/app/app_generator.rb | 1 | ||||
-rw-r--r-- | railties/lib/rails/test_help.rb | 1 | ||||
-rw-r--r-- | railties/test/generators/app_generator_test.rb | 1 |
3 files changed, 3 insertions, 0 deletions
diff --git a/railties/lib/rails/generators/rails/app/app_generator.rb b/railties/lib/rails/generators/rails/app/app_generator.rb index 0550bf113e..6b5f9090a2 100644 --- a/railties/lib/rails/generators/rails/app/app_generator.rb +++ b/railties/lib/rails/generators/rails/app/app_generator.rb @@ -125,6 +125,7 @@ module Rails def test empty_directory_with_keep_file 'test/fixtures' + empty_directory_with_keep_file 'test/fixtures/files' empty_directory_with_keep_file 'test/controllers' empty_directory_with_keep_file 'test/mailers' empty_directory_with_keep_file 'test/models' diff --git a/railties/lib/rails/test_help.rb b/railties/lib/rails/test_help.rb index c837fadb40..40a1915b54 100644 --- a/railties/lib/rails/test_help.rb +++ b/railties/lib/rails/test_help.rb @@ -21,6 +21,7 @@ if defined?(ActiveRecord::Base) class ActiveSupport::TestCase include ActiveRecord::TestFixtures self.fixture_path = "#{Rails.root}/test/fixtures/" + self.file_fixture_path = self.fixture_path + "files" end ActionDispatch::IntegrationTest.fixture_path = ActiveSupport::TestCase.fixture_path diff --git a/railties/test/generators/app_generator_test.rb b/railties/test/generators/app_generator_test.rb index 5d270555ed..4369e8362b 100644 --- a/railties/test/generators/app_generator_test.rb +++ b/railties/test/generators/app_generator_test.rb @@ -33,6 +33,7 @@ DEFAULT_APP_FILES = %w( log test/test_helper.rb test/fixtures + test/fixtures/files test/controllers test/models test/helpers |