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/generators/metal_generator_test.rb
2009-06-25 10:39:44 +02:00

18 lines
447 B
Ruby

require 'abstract_unit'
require 'generators/generators_test_helper'
require 'generators/rails/metal/metal_generator'
class MetalGeneratorTest < GeneratorsTestCase
def test_metal_skeleton_is_created
run_generator
assert_file "app/metal/foo.rb", /class Foo/
end
protected
def run_generator(args=[])
silence(:stdout) { Rails::Generators::MetalGenerator.start ["foo"].concat(args), :root => destination_root }
end
end