diff options
Diffstat (limited to 'railties/test/generators_test.rb')
-rw-r--r-- | railties/test/generators_test.rb | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/railties/test/generators_test.rb b/railties/test/generators_test.rb index fdd72d6361..674bdadf41 100644 --- a/railties/test/generators_test.rb +++ b/railties/test/generators_test.rb @@ -85,19 +85,20 @@ class GeneratorsTest < GeneratorsTestCase assert_match /Rails 2\.x generator/, output end - def test_builtin_generators - assert Rails::Generators.builtin.include?("rails:model") - end - def test_rails_generators_help_with_builtin_information output = capture(:stdout){ Rails::Generators.help } - assert_match /model/, output - assert_match /scaffold_controller/, output + assert_match /Rails:/, output + assert_match /^ model$/, output + assert_match /^ scaffold_controller$/, output end def test_rails_generators_with_others_information - output = capture(:stdout){ Rails::Generators.help }.split("\n").last - assert_equal "Others: active_record:fixjour, fixjour, foobar:foobar, mspec, rails:javascripts, xspec.", output + output = capture(:stdout){ Rails::Generators.help } + assert_match /ActiveRecord:/, output + assert_match /Fixjour:/, output + assert_match /^ active_record:model$/, output + assert_match /^ active_record:fixjour$/, output + assert_match /^ fixjour$/, output end def test_no_color_sets_proper_shell |