量角器测试中的自定义茉莉花记者 [英] Custom Jasmine reporter in Protractor tests
本文介绍了量角器测试中的自定义茉莉花记者的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我找不到如何使用 jasmine 框架更改量角器跑步者中的记者风格.
I can not find how to change reporter style in protractors runner using jasmine framework.
我现在拥有的是:
但我想要更多类似的东西:
But I would like something more like:
有没有办法为 jasmine 添加自定义报告器,以显示当前正在运行的测试而不是 DOTS 和 Fs?
推荐答案
我正在构建一个 jasmine 报告器,它完全符合您的要求,jasmine-spec-reporter.
I am building a jasmine reporter that does exactly what you want, jasmine-spec-reporter.
在 protractor.conf.js 中配置:
To configure in protractor.conf.js:
onPrepare: function(){
var SpecReporter = require('jasmine-spec-reporter').SpecReporter;
jasmine.getEnv().addReporter(new SpecReporter({displayStacktrace: 'all'}));
}
这篇关于量角器测试中的自定义茉莉花记者的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文