【问题标题】:In cucumber rakefile, one failure in any one of the rake load task, subsequent rakes are not running在黄瓜 rakefile 中,任何一项 rake 加载任务失败,后续 rake 未运行
【发布时间】:2017-04-14 18:13:10
【问题描述】:

如果我使用“rake sanityLoadTask”并且如果 task2 因某种原因失败,那么 task3 不会触发,则我有一个如下所示的 rakefile,并且在 cmd 中。 !!!!!!????

Cucumber::Rake::Task.new(:task1) 做 |t|

t.profile = '默认'

t.cucumber_opts = "-t @tag1"

结束

Cucumber::Rake::Task.new(:task2) 做|t|

t.profile = '默认'

t.cucumber_opts = "-t @tag2"

结束

Cucumber::Rake::Task.new(:task3) 做 |t|

t.profile = '默认'

t.cucumber_opts = "-t @tag3"

结束

加载任务

任务 :sanityLoadTask => [] 做

Rake::Task[:task1].execute

Rake::Task[:task2].execute

Rake::Task[:task3].execute

结束

【问题讨论】:

    标签: cucumber rake


    【解决方案1】:

    一旦 Cucumber rake 任务失败,它就会使 rake 程序停止。您可能希望在单独的进程中运行单个任务,以便如果它们中止,则 sanityLoadTask 的其余部分将运行。

    请参阅http://www.rakefieldmanual.com/fascicles/004-ignore-failed-tasks.html 了解解决方法。

    【讨论】:

      猜你喜欢
      • 2011-02-06
      • 2010-10-09
      • 2020-11-18
      • 2016-04-17
      • 1970-01-01
      • 2012-11-15
      • 1970-01-01
      • 2012-05-30
      • 1970-01-01
      相关资源
      最近更新 更多