From 0dc618caece7099b5fd75e47e1b5ba9fdb552f30 Mon Sep 17 00:00:00 2001 From: Mate Pek Date: Sat, 9 Mar 2024 14:15:47 +0700 Subject: [PATCH] mergeByLabel improvements; Catch2 parser improvements --- .gitignore | 2 ++ CHANGELOG.md | 7 +++++++ src/framework/Catch2/Catch2Executable.ts | 11 +++++++++++ src/framework/SharedVarOfExec.ts | 2 +- test/cpp/.vscode/settings.json | 1 - 5 files changed, 21 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 4c9f0c7a..fa3939ee 100644 --- a/.gitignore +++ b/.gitignore @@ -5,8 +5,10 @@ node_modules out /test/cpp/build +/test/cpp/.vscode/ *.vsix .vscode-test .vscode/ipch + diff --git a/CHANGELOG.md b/CHANGELOG.md index 47f8fd38..aebdfde2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,13 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ## [Unreleased] +## [4.11.0] + +### Changed + +- from now `mergeByLabel` configuration only takes `env` in account. ([related](https://github.com/matepek/vscode-catch2-test-adapter/issues/427)) +- Catch2 parser improvements ([related](https://github.com/matepek/vscode-catch2-test-adapter/issues/428)) + ## [4.10.0] - 2024-03-05 ### Added/Changed/Removed diff --git a/src/framework/Catch2/Catch2Executable.ts b/src/framework/Catch2/Catch2Executable.ts index cd326b3e..a15c549c 100644 --- a/src/framework/Catch2/Catch2Executable.ts +++ b/src/framework/Catch2/Catch2Executable.ts @@ -501,6 +501,17 @@ abstract class TagProcessorBase implements XmlTagProcessor { } }, ], + [ + 'OverallResultsCases', + (tag: XmlTag, builder: TestResultBuilder, _shared: SharedVarOfExec) => { + builder.setDurationMilisec(parseFloat(tag.attribs.durationInSeconds) * 1000); + if (tag.attribs.failures !== '0') { + builder.failed(); + } else { + builder.passed(); + } + }, + ], [ 'Expression', (tag: XmlTag, builder: TestResultBuilder, shared: SharedVarOfExec): XmlTagProcessor => diff --git a/src/framework/SharedVarOfExec.ts b/src/framework/SharedVarOfExec.ts index c792e198..c43fec2d 100644 --- a/src/framework/SharedVarOfExec.ts +++ b/src/framework/SharedVarOfExec.ts @@ -27,7 +27,7 @@ export class SharedVarOfExec { readonly resolvedSourceFileMap: Record, ) { this.parallelizationPool = new TaskPool(_parallelizationLimit); - this.optionsHash = hash.MD5(options).substring(0, 6); + this.optionsHash = hash.MD5(options.env).substring(0, 6); } readonly parallelizationPool: TaskPool; diff --git a/test/cpp/.vscode/settings.json b/test/cpp/.vscode/settings.json index 1b73bdd8..53ba47ac 100644 --- a/test/cpp/.vscode/settings.json +++ b/test/cpp/.vscode/settings.json @@ -3,7 +3,6 @@ "testMate.cpp.test.advancedExecutables": [ { "pattern":"build/**/*{test,Test,TEST}*", - "exclude": "files.watcherExcludee", "runTask": { // "before": ["build_all"] }