提交 5df9d008 编写于 作者: S siong1987

add test case for turn gem for testunit.

上级 9773f6e1
...@@ -202,6 +202,14 @@ def test_javascript_is_skipped_if_required ...@@ -202,6 +202,14 @@ def test_javascript_is_skipped_if_required
end end
end end
def test_inclusion_of_turn_gem_in_gemfile
run_generator
assert_file "Gemfile" do |contents|
assert_match /gem 'turn'/, contents unless RUBY_VERSION < '1.9.2'
assert_no_match /gem 'turn'/, contents if RUBY_VERSION < '1.9.2'
end
end
def test_template_from_dir_pwd def test_template_from_dir_pwd
FileUtils.cd(Rails.root) FileUtils.cd(Rails.root)
assert_match /It works from file!/, run_generator([destination_root, "-m", "lib/template.rb"]) assert_match /It works from file!/, run_generator([destination_root, "-m", "lib/template.rb"])
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册