木偶规格和测试厨房

时间:2015-02-12 07:03:41

标签: puppet serverspec

如何覆盖serverspec的日志格式并在单独的文件中提取? 我能够做到这一点,但无法在单独的文件中提取。

我的代码段是:

RSpec.configure do |c|
  c.output_stream = File.open('serverspec-result.json', 'w')
end

当我正在运行kitchen test时,它会给我以下警告:

RSpec's reporter has already been initialized with 
#<IO:<STDOUT>> as the output stream,
so your change to `output_stream` will be ignored. 
You should configure it earlier for it to take effect.

0 个答案:

没有答案