From c2ce154a159db884ef71999d52d6fe57c6b081c2 Mon Sep 17 00:00:00 2001 From: Wilfried Goesgens Date: Wed, 24 Oct 2018 16:02:17 +0200 Subject: [PATCH] initialize the testresult summary with an abort message, in case we don't finish successfully (#7046) --- UnitTests/unittest.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/UnitTests/unittest.js b/UnitTests/unittest.js index 271077399a..05674bc973 100644 --- a/UnitTests/unittest.js +++ b/UnitTests/unittest.js @@ -220,6 +220,13 @@ function main (argv) { try { fs.write(testOutputDirectory + '/UNITTEST_RESULT_EXECUTIVE_SUMMARY.json', "false", true); fs.write(testOutputDirectory + '/UNITTEST_RESULT_CRASHED.json', "true", true); + let testFailureText = 'testfailures.txt'; + if (options.hasOwnProperty('testFailureText')) { + testFailureText = options.testFailureText; + } + fs.write(fs.join(testOutputDirectory, testFailureText), + "Incomplete testrun with these testsuites: '" + testSuits + + "'\nand these options: " + JSON.stringify(options) + "\n"); } catch (x) { print('failed to write default test result: ' + x.message); throw(x);