public inbox for dev@dpdk.org
 help / color / mirror / Atom feed
* [PATCH v1] dts: update overall result pass/skip logic
@ 2026-03-13 15:56 Dean Marx
  2026-03-13 17:07 ` Andrew Bailey
  2026-03-13 18:22 ` [PATCH v2] " Dean Marx
  0 siblings, 2 replies; 11+ messages in thread
From: Dean Marx @ 2026-03-13 15:56 UTC (permalink / raw)
  To: probb, luca.vizzarro, yoan.picchi, Honnappa.Nagarahalli,
	paul.szczepanek
  Cc: dev, Dean Marx

Update overall result of test suites such that
when some cases skip and at least one passes,
the result is a pass instead of a skip. Only
when all cases skip is the result a skip.

Bugzilla ID: 1899

Signed-off-by: Dean Marx <dmarx@iol.unh.edu>
---
 dts/framework/test_result.py | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/dts/framework/test_result.py b/dts/framework/test_result.py
index c6bddc55a9..0a43c23c04 100644
--- a/dts/framework/test_result.py
+++ b/dts/framework/test_result.py
@@ -195,10 +195,11 @@ def extract_result(value: ResultNode | ResultLeaf) -> ResultLeaf:
                 case ResultLeaf():
                     return value
 
-        return max(
-            (extract_result(child) for child in self.children),
-            default=ResultLeaf(result=Result.PASS),
-        )
+        results = [extract_result(child) for child in self.children]
+        max_result = max(results, default=ResultLeaf(result=Result.PASS))
+        if max_result.result == Result.SKIP and any(r.result == Result.PASS for r in results):
+            return ResultLeaf(result=Result.PASS)
+        return max_result
 
     def make_summary(self) -> Counter[Result]:
         """Make the summary of the underlying results while ignoring special nodes."""
-- 
2.52.0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-03-23 14:01 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-13 15:56 [PATCH v1] dts: update overall result pass/skip logic Dean Marx
2026-03-13 17:07 ` Andrew Bailey
2026-03-13 18:22 ` [PATCH v2] " Dean Marx
2026-03-16 16:17   ` Patrick Robb
2026-03-20  4:26   ` Patrick Robb
2026-03-20 10:41   ` Luca Vizzarro
2026-03-20 15:36     ` Dean Marx
2026-03-20 15:46   ` [PATCH v3] " Dean Marx
2026-03-20 18:21     ` [PATCH v4] " Dean Marx
2026-03-20 21:09       ` Patrick Robb
2026-03-23 14:01       ` Luca Vizzarro

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox