【问题标题】:Rails - How can I run cucumber tests only?Rails - 我怎样才能只运行黄瓜测试?
【发布时间】:2012-08-23 06:24:42
【问题描述】:

我可以使用rake:models 运行所有模型

有什么选项可以为黄瓜测试而不是 rake 并在所有级别运行所有测试?

我试过了:

$ rake spec:cucumber
rake aborted!
Don't know how to build task 'spec:cucumber'

【问题讨论】:

  • @janders223 有正确的答案。澄清一下,Rspec 与 Cucumber 无关,这就是为什么没有 rake spec:cucumber 这样的东西。

标签: ruby-on-rails ruby testing cucumber rake


【解决方案1】:

你应该可以运行rake cucumber

rake -T 的快速输出显示:

rake cucumber                          # Alias for cucumber:ok
rake cucumber:all                      # Run all features
rake cucumber:ok                       # Run features that should pass
rake cucumber:rerun                    # Record failing features and run only them if any exist
rake cucumber:wip                      # Run features that are being worked on

【讨论】:

  • 只是添加,你也可以只使用cucumber脚本而不用rake。
  • 非常正确,还可以运行rake cucumber:ok spec 来同时运行所有功能和规格。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 2020-03-28
  • 1970-01-01
  • 1970-01-01
  • 2014-09-24
  • 1970-01-01
  • 1970-01-01
  • 2020-09-01
相关资源
最近更新 更多