Shell Recorder: Always print protocol for failures
Before this update the Shell Recorder would not print the protocol
for a failed test, if the test modified the database permanently.
@@ -287,12 +287,6 @@ run_script
"$KDB" rm -r "$MountpointRoot" 2> /dev/null
"$KDB" import "$MountpointRoot" dump 2> /dev/null < "$TMPFILE"
-# We disable the cleanup procedure temporarily, since we still need the exported configuration,
-# if the tests changed the configuration permanently.
-trap - EXIT
-export_check "$EXPORT_DIR" 'Test'
-trap cleanup EXIT
-
EVAL=0
if [ "$#" -eq '1' ]; then
@@ -317,5 +311,11 @@ if [ "$EVAL" -ne 0 ] || [ $printProtocol = 'true' ]; then
fi
rm -f "$OutFile"
+# We disable the cleanup procedure temporarily, since we still need the exported configuration,
+# if the tests changed the configuration permanently.
+trap - EXIT
+export_check "$EXPORT_DIR" 'Test'
+trap cleanup EXIT
+
rm "${TMPFILE}"
exit "$EVAL"
