From 8e5fb5ffa9adb4ffa5feebdbf24525c262eea41d Mon Sep 17 00:00:00 2001 From: yann300 Date: Thu, 16 Aug 2018 16:31:51 +0200 Subject: [PATCH] add "no test file available" --- src/app/tabs/test-tab.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/app/tabs/test-tab.js b/src/app/tabs/test-tab.js index 0b00d960d6..bca4c5d254 100644 --- a/src/app/tabs/test-tab.js +++ b/src/app/tabs/test-tab.js @@ -109,7 +109,13 @@ module.exports = class TestTab { if (error) return tooltip(error) self.data.allTests = tests self.data.selectedTests = [...self.data.allTests] - yo.update(self.testList, yo`
${listTests()}
`) + if (!tests.length) { + yo.update(self.testList, yo`
No test file available
`) + } else { + yo.update(self.testList, yo`
${listTests()}
`) + } + testsOutput.hidden = true + testsSummary.hidden = true testsOutput.innerHTML = '' testsSummary.innerHTML = '' })