Permalink
Browse files

Don't be verbose while creating dummy application in plugin new gener…

…ator
  • Loading branch information...
1 parent 013fc0a commit 489b279fc499f135df48556554739c19d316df0a @drogus committed Oct 28, 2010
View
@@ -6,6 +6,8 @@ else
gem "arel", :git => "git://github.com/rails/arel.git"
end
+gem "thor", :git => "git://github.com/wycats/thor.git"
+
gem "rack", :git => "git://github.com/rack/rack.git"
gem "rails", :path => File.dirname(__FILE__)
@@ -146,16 +146,22 @@ def create_test_files
def create_test_dummy_files
say_status :vendor_app, dummy_path
- build(:generate_test_dummy)
+ mute do
+ build(:generate_test_dummy)
+ end
end
def change_config_files
store_application_definition!
- build(:test_dummy_config)
+ mute do
+ build(:test_dummy_config)
+ end
end
def remove_uneeded_rails_files
- build(:test_dummy_clean)
+ mute do
+ build(:test_dummy_clean)
+ end
end
def finish_template
@@ -219,6 +225,10 @@ def get_builder_class
builder.send(name) if builder.respond_to?(name)
end
end
+
+ def mute(&block)
+ shell.mute(&block)
+ end
end
end
end
@@ -103,6 +103,10 @@ def test_creating_engine_in_full_mode
assert_file "lib/bukkits.rb", /require "bukkits\/engine"/
end
+ def test_being_quiet_while_creating_dummy_application
+ assert_no_match /create\s+config\/application.rb/, run_generator
+ end
+
protected
def action(*args, &block)

0 comments on commit 489b279

Please sign in to comment.