Skip to content

Low: cts: Consolidate tests in cts-lab result output#4062

Merged
clumens merged 1 commit intoClusterLabs:mainfrom
clumens:t1018
Mar 16, 2026
Merged

Low: cts: Consolidate tests in cts-lab result output#4062
clumens merged 1 commit intoClusterLabs:mainfrom
clumens:t1018

Conversation

@clumens
Copy link
Copy Markdown
Contributor

@clumens clumens commented Feb 23, 2026

It's possible to run the same test multiple times, like so:

--choose "ComponentFail ComponentFail"

If you do, the test summary will list each one individually:

Jan 31 09:28:13 Test ComponentFail {'calls': 1, 'failure': 0, 'skipped': 0, 'auditfail': 0}
Jan 31 09:28:13 Test ComponentFail {'calls': 1, 'failure': 0, 'skipped': 0, 'auditfail': 0}

Instead, these can be condensed into a single row:

Feb 23 13:42:38 rhel9-ctslab-exec Test ComponentFail {'calls': 2, 'failure': 0, 'skipped': 0, 'auditfail': 0}

Note that I've chosen to leave the detailed results as they are. This is because the details results may contain other information that differs from run to run, even of the same test, and we may want to see that.

Fixes T1018

It's possible to run the same test multiple times, like so:

--choose "ComponentFail ComponentFail"

If you do, the test summary will list each one individually:

Jan 31 09:28:13	Test ComponentFail        {'calls': 1, 'failure': 0, 'skipped': 0, 'auditfail': 0}
Jan 31 09:28:13	Test ComponentFail        {'calls': 1, 'failure': 0, 'skipped': 0, 'auditfail': 0}

Instead, these can be condensed into a single row:

Feb 23 13:42:38 rhel9-ctslab-exec Test ComponentFail        {'calls': 2, 'failure': 0, 'skipped': 0, 'auditfail': 0}

Note that I've chosen to leave the detailed results as they are.  This
is because the details results may contain other information that
differs from run to run, even of the same test, and we may want to see
that.

Fixes T1018
@clumens clumens requested a review from nrwahl2 February 23, 2026 19:58
stat_summary[test.name][key] += test.stats[key]

self._cm.log(f"{f'Test {test.name}':<25} {stat_filter!r}")
for (name, summary) in stat_summary.items():
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Order isn't guaranteed here. I think for consistency with the other cts-lab modes, we should sort according to the order in tests.test_list. That becomes a bit more complicated than it should be, because self.tests is set to the full list of tests in the other modes -- for this mode (Sequence), it's set to the list of tests that were actually specified on the command line.

It would also be reasonable to sort based on the order in which the tests were specified, though that's also a tad ugly with this current dict-based implementation.


I briefly looked into doing this. I don't think we should hold up this PR further over it. There are a number of changes that would be helpful, to do this cleanly. I really shouldn't let myself spend more time on it.

@clumens clumens merged commit ae2b2df into ClusterLabs:main Mar 16, 2026
1 check passed
@clumens clumens deleted the t1018 branch March 16, 2026 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants