diff options
Diffstat (limited to 'railties/test/generators')
-rw-r--r-- | railties/test/generators/actions_test.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/railties/test/generators/actions_test.rb b/railties/test/generators/actions_test.rb index 56cb53c1ad..94e9abb3cc 100644 --- a/railties/test/generators/actions_test.rb +++ b/railties/test/generators/actions_test.rb @@ -102,6 +102,20 @@ class ActionsTest < Rails::Generators::TestCase assert_file 'Gemfile', /gem "rspec-rails"$/ end + def test_gem_group_should_wrap_gems_in_a_group + run_generator + + action :gem_group, :development, :test do + gem 'rspec-rails' + end + + action :gem_group, :test do + gem 'fakeweb' + end + + assert_file 'Gemfile', /\ngroup :development, :test do\n gem "rspec-rails"\nend\n\ngroup :test do\n gem "fakeweb"\nend/ + end + def test_environment_should_include_data_in_environment_initializer_block run_generator autoload_paths = 'config.autoload_paths += %w["#{Rails.root}/app/extras"]' |