From 9786ce3d07cf184a664ef44c0e9fcf5db2ac74ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= Date: Thu, 14 Feb 2019 17:45:40 +0100 Subject: [PATCH] Testsuite: display full stacktrace on Octave failures --- tests/printMakeCheckOctaveErrMsg.m | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/printMakeCheckOctaveErrMsg.m b/tests/printMakeCheckOctaveErrMsg.m index 84e19d00e..ed66ea68c 100644 --- a/tests/printMakeCheckOctaveErrMsg.m +++ b/tests/printMakeCheckOctaveErrMsg.m @@ -6,9 +6,11 @@ function printMakeCheckOctaveErrMsg(modfilename, err) printf(" WHILE RUNNING MODFILE: %s\n", modfilename); printf(" MSG: %s\n", err.message); if (isfield(err, 'stack')) - printf(" IN FILE: %s\n", err.stack(1).file); - printf(" IN FUNCTION: %s\n", err.stack(1).name); - printf(" ON LINE and COLUMN: %d and %d\n",err.stack(1).line,err.stack(1).column); + printf("\n STACKTRACE:\n"); + for i=1:size(err.stack, 1) + printf(" %s(%s):%d.%d\n", err.stack(i).file, err.stack(i).name, + err.stack(i).line, err.stack(i).column); + endfor end - printf("*************************************\n\n\n"); + printf("********************************************\n\n\n"); end