null+****@clear*****
null+****@clear*****
2012年 3月 5日 (月) 17:52:25 JST
Kouhei Sutou 2012-03-05 17:52:25 +0900 (Mon, 05 Mar 2012) New Revision: da936233f80fdc3aaf012249f01ccf89af86a157 Log: Save actual result Modified files: bin/groonga-test Modified: bin/groonga-test (+10 -0) =================================================================== --- bin/groonga-test 2012-03-05 17:52:18 +0900 (0b47edb) +++ bin/groonga-test 2012-03-05 17:52:25 +0900 (4405257) @@ -67,10 +67,12 @@ class GroongaTester @reporter.pass_test else @reporter.fail_test(expected_result, actual_result) + output_actual_result(actual_result, test_script_path, ".reject") succeeded = false end else @reporter.no_check_test(actual_result) + output_actual_result(actual_result, test_script_path, ".actual") end @reporter.finish_test @@ -152,6 +154,14 @@ class GroongaTester end end + def output_actual_result(actual_result, test_script_path, suffix) + result_path_name = test_script_path.to_s.gsub(/\..+?\z/, suffix) + result_path = Pathname(result_path_name) + result_path.open("w:ascii-8bit") do |result_file| + result_file.print(actual_result) + end + end + def detect_suitable_diff if command_exist?("cut-diff") @diff = "cut-diff"