From e26b9fc549e26e72c68f48ac6a16b208f1821140 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 23 Sep 2020 12:39:38 +0200 Subject: [PATCH] [Backport 7.x] Fixed integration test runner (#1319) Co-authored-by: Tomas Della Vedova --- test/integration/index.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/integration/index.js b/test/integration/index.js index 571baa88e..7c3c73032 100644 --- a/test/integration/index.js +++ b/test/integration/index.js @@ -19,6 +19,11 @@ 'use strict' +process.on('unhandledRejection', function (err) { + console.error(err) + process.exit(1) +}) + const { writeFileSync, readFileSync, accessSync, mkdirSync, readdirSync, statSync } = require('fs') const { join, sep } = require('path') const yaml = require('js-yaml') @@ -197,8 +202,11 @@ async function start ({ client, isXPack }) { const tests = data .split('\n---\n') .map(s => s.trim()) + // empty strings .filter(Boolean) .map(parse) + // null values + .filter(Boolean) // get setup and teardown if present var setupTest = null