Yoji Shidara
null+****@clear*****
Thu Sep 19 17:27:18 JST 2013
Yoji Shidara 2013-09-19 17:27:18 +0900 (Thu, 19 Sep 2013) New Revision: cf6a7e8384a8d3a6a4a582eae76d638db4104d1c https://github.com/droonga/drntest/commit/cf6a7e8384a8d3a6a4a582eae76d638db4104d1c Message: Generate destination paths in _path methods Modified files: lib/drntest/test-runner.rb Modified: lib/drntest/test-runner.rb (+7 -4) =================================================================== --- lib/drntest/test-runner.rb 2013-09-19 17:24:40 +0900 (716dca4) +++ lib/drntest/test-runner.rb 2013-09-19 17:27:18 +0900 (4de13ec) @@ -69,20 +69,23 @@ module Drntest target_path.sub_ext(".reject") end + def actual_path + target_path.sub_ext(".actual") + end + def remove_reject_file FileUtils.rm_rf(reject_path, :secure => true) end def output_reject_file(actual_result) - output_actual_result(actual_result, ".reject") + output_actual_result(actual_result, reject_path) end def output_actual_file(actual_result) - output_actual_result(actual_result, ".actual") + output_actual_result(actual_result, actual_path) end - def output_actual_result(actual_result, suffix) - output_path = target_path.sub_ext(suffix) + def output_actual_result(actual_result, output_path) puts "Saving received result as #{output_path}" actual_json = JSON.pretty_generate(actual_result) File.write(output_path, actual_json) -------------- next part -------------- HTML����������������������������...Download