私は現在、rcovをHudsonサーバーと統合するために取り組んでいます。
rakeを介してrcovを実行し、問題なく結果を得ることができます(以下のrakeファイルを参照)。ハドソンを介して物事を実行すると(レーキタスクを呼び出します)、カバレッジのあるテストが明確に生成され、コンソールに表示されます。
しかし、ほぼ最後に、コンソールに次のように表示されます。
** Execute test:coverage
Recording test results
No test report files were found. Configuration error?
Build wasn't successful, skipping rcov coverage report
Finished: FAILURE
レーキタスク
desc 'Aggregate code coverage for unit, functional and integration tests'
task :coverage => "test:coverage:clean"
%w[unit functional].each do |target|
namespace :coverage do
Rcov::RcovTask.new(target) do |t|
t.libs << "test"
t.test_files = FileList["test/#{target}/*_test.rb"]
t.output_dir = "coverage"
t.verbose = true
t.rcov_opts << '--rails --aggregate coverage.data'
end
end
task :coverage => "test:coverage:#{target}"
end
カバレッジに移動/出力ファイルが表示されます。Coverage.dataファイルも存在します。
ここで何がうまくいかないのかについて何か考えはありますか?私は盲目的に明白な何かを見逃していますか?