1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

create the dummy app if there's no test_unit but there's a dummy_path

This commit is contained in:
dmathieu 2011-05-24 13:18:27 +02:00
parent b8118ef492
commit 3d9d9f86f5
2 changed files with 8 additions and 1 deletions

View file

@ -202,7 +202,7 @@ task :default => :test
end
def create_test_dummy_files
return if options[:skip_test_unit]
return if options[:skip_test_unit] && options[:dummy_path] == 'test/dummy'
create_dummy_app
end

View file

@ -182,6 +182,13 @@ class PluginNewGeneratorTest < Rails::Generators::TestCase
assert_file "spec/dummy/config/application.rb"
assert_no_file "test/dummy"
end
def test_creating_dummy_without_tests_but_with_dummy_path
run_generator [destination_root, "--dummy_path", "spec/dummy", "--skip-test-unit"]
assert_file "spec/dummy"
assert_file "spec/dummy/config/application.rb"
assert_no_file "test"
end
def test_skipping_gemspec
run_generator [destination_root, "--skip-gemspec"]