From aa4686fb5c9e543a4bbe1ead7e434359050bb0f0 Mon Sep 17 00:00:00 2001 From: Vasileios Karakasis Date: Mon, 24 Aug 2026 15:23:21 +0200 Subject: [PATCH] Fix reporting of failing performance variable Signed-off-by: Vasileios Karakasis --- reframe/core/pipeline.py | 1 + unittests/test_pipeline.py | 12 +++++++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/reframe/core/pipeline.py b/reframe/core/pipeline.py index a5cbb542e..c3878b78b 100644 --- a/reframe/core/pipeline.py +++ b/reframe/core/pipeline.py @@ -3180,6 +3180,7 @@ def _fmt_errors(errlist, indent=''): # Check the performance variables against their references. errors = _PerfErrorBuilder() for key, values in self._perfvalues.items(): + tag = key.split(':')[-1] val, ref, low_thres, high_thres, unit, _ = values # Verify that val is a number diff --git a/unittests/test_pipeline.py b/unittests/test_pipeline.py index 8cd988ffa..5bd2ec62a 100644 --- a/unittests/test_pipeline.py +++ b/unittests/test_pipeline.py @@ -2348,7 +2348,17 @@ def reftuple(status): if exctype is None: _run_sanity(perftest, *local_exec_ctx) else: - with pytest.raises(exctype): + def _validate_exc(err): + if value2_status == 'pass': + print(err) + return 'value2' not in err.args[0] + if value1_status == 'pass': + print(err) + return 'value1' not in err.args[0] + + return True + + with pytest.raises(exctype, check=_validate_exc): _run_sanity(perftest, *local_exec_ctx)