- ok $? "Read the new trace in ${out_path}"
-
- new_cnt=$($BABELTRACE_BIN ${out_path} 2>/dev/null | wc -l)
-
- test $orig_cnt == $new_cnt
- ok $? "Same number of events as the original trace ($orig_cnt -> $new_cnt)"
-
- rm -rf ${out_path}
+ if test $? != 0; then
+ fail "Read the new trace in ${out_path}"
+ continue
+ fi
+ ok 0 "Read the new trace in ${out_path}"
+
+ $BABELTRACE_BIN ${out_path} 2>/dev/null >${text_output2}
+ cnt=$(diff ${text_output1} ${text_output2} | wc -l)
+ test $? == 0
+ ok $? "Exact same content between the two traces"
+
+ rm -rf ${out_path} ${text_output} ${text_output2}