我正在使用jasmine-gem作为rails项目的一部分。
我知道我可以在rake jasmine
的浏览器中运行测试,但我需要通过rake jasmine:ci
无头运行它们。
当我在headless / ci模式下运行时,console.log
s不会输出。我怎么能做到这一点?也许是jasmine_helper.rb
中的某些内容?
答案 0 :(得分:3)
想出来。
在jasmine_helpers.rb
:
Jasmine.configure do |config|
config.show_console_log = true
end
答案 1 :(得分:3)
您可以通过在jasmine.yml
文件中添加以下内容来完成此操作:
show_console_log: true