From 41e145556f0d41074f1e5e3da806bbc2f2e505c2 Mon Sep 17 00:00:00 2001 From: "A.J. Kaptijn" Date: Fri, 22 Mar 2024 10:53:27 +0100 Subject: [PATCH] . --- dist/index.js | 2 +- src/main.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/index.js b/dist/index.js index 75e2141..097c824 100644 --- a/dist/index.js +++ b/dist/index.js @@ -382,7 +382,7 @@ class TestReporter { if (tr.failed === 0) return; let runName = tr.path.slice(0, tr.path.indexOf('/TestResults/')); - runName = runName.slice(0, tr.path.indexOf('test/')); + runName = runName.startsWith('test/') ? runName.slice(5) : runName; req.blocks.push({ type: 'section', text: { diff --git a/src/main.ts b/src/main.ts index df6e6c3..0d3128a 100644 --- a/src/main.ts +++ b/src/main.ts @@ -327,7 +327,7 @@ class TestReporter { results.map((tr, runIndex) => { if (tr.failed === 0) return let runName = tr.path.slice(0, tr.path.indexOf('/TestResults/')) - runName = runName.slice(0, tr.path.indexOf('test/')) + runName = runName.startsWith('test/') ? runName.slice(5) : runName req.blocks.push({ type: 'section',