1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/railties/test/engine/commands_tasks_test.rb
yuuji.yaginuma 6fc8b54621 add missing require rake
In ff8035dfee, require rake is deferred.
Therefore, it is necessary to require rake even `Engine::CommandsTasks.
2016-08-11 20:54:23 +09:00

24 lines
568 B
Ruby

require "abstract_unit"
class Rails::Engine::CommandsTasksTest < ActiveSupport::TestCase
def setup
@destination_root = Dir.mktmpdir("bukkits")
Dir.chdir(@destination_root) { `bundle exec rails plugin new bukkits --mountable` }
end
def teardown
FileUtils.rm_rf(@destination_root)
end
def test_help_command_work_inside_engine
output = capture(:stderr) do
Dir.chdir(plugin_path) { `bin/rails --help` }
end
assert_no_match "NameError", output
end
private
def plugin_path
"#{@destination_root}/bukkits"
end
end