简体   繁体   English

Test :: unit和Rubymine“未找到测试”

[英]Test::unit and Rubymine “No tests were found”

I'm a newbie in Ruby and I try to use the test::unit framework with the RubyMine IDE (3.1.1). 我是Ruby的新手,我尝试在RubyMine IDE(3.1.1)中使用test :: unit框架。

I don't understand the note about test::unit here: http://www.jetbrains.com/ruby/webhelp/test-unit-special-note.html 我不了解有关test :: unit的注释, 网址为http : //www.jetbrains.com/ruby/webhelp/test-unit-special-note.html

Specially this instruction: "Include test-unit gem in your Gemfile." 特别是以下说明:“在Gemfile中包含测试单元gem。” I use gem install "test-unit" and attach it to my project but I still got 0 tests and the error message "No tests were found" 我使用gem install“ test-unit”并将其附加到我的项目中,但是我仍然得到0个测试,并且错误消息“未找到测试”

There is another reason that can cause some scenario not to be recognized. 还有另一个原因可能导致某些情况无法识别。 If there is an scenario with the same name in other feature, it may cause your scenario not to be detected. 如果在其他功能中存在具有相同名称的方案,则可能导致无法检测到您的方案。

确保项目根目录中有一个Gemfile ,其中包含:

gem 'test-unit'

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM