diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2014-10-23 05:34:16 -0700 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2014-10-23 05:34:16 -0700 |
commit | 26e6ec20da4e85849d0688db5fd580056ebdfed9 (patch) | |
tree | 6ad9817568e1f40e095534993eb49bb5008e8bf7 /scripts/run_tests.sh | |
parent | 3b397c56ed2b851b07bca3a7c7d38cb0e7cb53f3 (diff) | |
download | qtlocation-mapboxgl-26e6ec20da4e85849d0688db5fd580056ebdfed9.tar.gz |
show that the program crashed
Diffstat (limited to 'scripts/run_tests.sh')
-rwxr-xr-x | scripts/run_tests.sh | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/scripts/run_tests.sh b/scripts/run_tests.sh index e9952e46be..df0bf25216 100755 --- a/scripts/run_tests.sh +++ b/scripts/run_tests.sh @@ -3,15 +3,21 @@ set -e set -o pipefail -# allow writing core files -ulimit -c unlimited -S cd build/${BUILDTYPE:-Release} for TEST in ./test_* ; do + # allow writing core files + ulimit -c unlimited -S + RESULT=0 ${TEST} || RESULT=$? + if [[ ${RESULT} != 0 ]]; then + echo "The program crashed with exit code ${RESULT}. We're now trying to output the core dump." + ls -la + fi + # output core dump if we got one for DUMP in $(find ./ -maxdepth 1 -name 'core*' -print); do gdb ${TEST} ${DUMP} -ex "thread apply all bt" -ex "set pagination 0" -batch |