Merge pull request #2454 from tastywheattasteslikechicken/FixVtableAbort
[mono.git] / mono / mini / test_op_il_seq_point.sh
index 5df176e4755c968607feee268744df3ab860bb28..eb42a0279c1faf464a2b0840c7a8b611d95a4a2b 100755 (executable)
@@ -16,7 +16,7 @@ tmp_file () {
 }
 
 clean_aot () {
-       rm -rf *.exe..so *.exe.dylib *.exe.dylib.dSYM
+       rm -rf *.exe.so *.exe.dylib *.exe.dylib.dSYM
 }
 
 # The test compares the generated native code size between a compilation with and without seq points.
@@ -89,27 +89,29 @@ while read line; do
        fi
 done < $TMP_FILE
 
-echo -n "              <test-case name=\"MonoTests.op_il_seq_point.${TEST_FILE}${USE_AOT}\" executed=\"True\" time=\"0\" asserts=\"0\" success=\"" >> TestResults_op_il_seq_point.xml
+TESTRESULT_FILE=TestResult-op_il_seq_point.tmp
+
+echo -n "              <test-case name=\"MonoTests.op_il_seq_point.${TEST_FILE}${USE_AOT}\" executed=\"True\" time=\"0\" asserts=\"0\" success=\"" >> $TESTRESULT_FILE
 
 if [ $CHANGES != 0 ]
 then
        METHOD_NAME=$(get_method_name "$METHOD")
 
-       echo "False\">" >> TestResults_op_il_seq_point.xml
-       echo "                <failure>" >> TestResults_op_il_seq_point.xml
-       echo -n "                  <message><![CDATA[" >> TestResults_op_il_seq_point.xml
-       echo "Detected OP_IL_SEQ_POINT incompatibility on $TEST_FILE" >> TestResults_op_il_seq_point.xml
-       echo "  $CHANGES methods differ when sequence points are enabled." >> TestResults_op_il_seq_point.xml
-       echo '  This is probably caused by a runtime optimization that is not handling OP_IL_SEQ_POINT' >> TestResults_op_il_seq_point.xml
-       echo '' >> TestResults_op_il_seq_point.xml
-       echo "Diff $METHOD_NAME" >> TestResults_op_il_seq_point.xml
-       echo "Without IL_OP_SEQ_POINT                                                         With IL_OP_SEQ_POINT" >> TestResults_op_il_seq_point.xml
-       echo -n "$(diff_method $MONO_PATH $RUNTIME $TEST_FILE $METHOD_NAME $USE_AOT)" >> TestResults_op_il_seq_point.xml
-       echo "]]></message>" >> TestResults_op_il_seq_point.xml
-       echo "                  <stack-trace>" >> TestResults_op_il_seq_point.xml
-       echo "                  </stack-trace>" >> TestResults_op_il_seq_point.xml
-       echo "                </failure>" >> TestResults_op_il_seq_point.xml
-       echo "              </test-case>" >> TestResults_op_il_seq_point.xml
+       echo "False\">" >> $TESTRESULT_FILE
+       echo "                <failure>" >> $TESTRESULT_FILE
+       echo -n "                  <message><![CDATA[" >> $TESTRESULT_FILE
+       echo "Detected OP_IL_SEQ_POINT incompatibility on $TEST_FILE" >> $TESTRESULT_FILE
+       echo "  $CHANGES methods differ when sequence points are enabled." >> $TESTRESULT_FILE
+       echo '  This is probably caused by a runtime optimization that is not handling OP_IL_SEQ_POINT' >> $TESTRESULT_FILE
+       echo '' >> $TESTRESULT_FILE
+       echo "Diff $METHOD_NAME" >> $TESTRESULT_FILE
+       echo "Without IL_OP_SEQ_POINT                                                         With IL_OP_SEQ_POINT" >> $TESTRESULT_FILE
+       echo -n "$(diff_method $MONO_PATH $RUNTIME $TEST_FILE $METHOD_NAME $USE_AOT)" >> $TESTRESULT_FILE
+       echo "]]></message>" >> $TESTRESULT_FILE
+       echo "                  <stack-trace>" >> $TESTRESULT_FILE
+       echo "                  </stack-trace>" >> $TESTRESULT_FILE
+       echo "                </failure>" >> $TESTRESULT_FILE
+       echo "              </test-case>" >> $TESTRESULT_FILE
 
        echo ''
        echo "Detected OP_IL_SEQ_POINT incompatibility on $TEST_FILE"
@@ -122,5 +124,5 @@ then
        echo "$(diff_method $MONO_PATH $RUNTIME $TEST_FILE $METHOD_NAME $USE_AOT)"
        exit 1
 else
-       echo "True\" />" >> TestResults_op_il_seq_point.xml
+       echo "True\" />" >> $TESTRESULT_FILE
 fi