Add test case stats functionality and test case name priority output #2946
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Add 2 new flags
--output-test-case-name-first
and--output-test-case-stats
. Former will print name of the test case before it is run (as was requested here) and the latter will print regularTestCaseName: **stats**
. I've seen #2343 so this is a bit more lightweight and hopefully not too much against the grain with the argument namespace polution. idklmkAs is mentioned in refed issue, I was missing this feature as well and as much as I want to understand why it's not yet implemented I don't, but I understand why it's not the default.
This is more of a proposal as I'm not really confident with the naming and even worse, I'm using catch for like 3 days now, so I know very little about its internals and overall design.
With that said, I'd be glad to get some feedback. If this feature will be considered, I'll try to polish this PR more with tests and everything, but for that I'll need to look a bit deeper into docs.
I would split these "features" into two, but because of non-buffered output, there are some interdependencies because of newlines already (as with
-s
and-d yes
would be and idk how many more flags that configure output) between these two, so I wanted to keep them together.Also atm. I have no idea what table printer does so all I've really done is just ran it, saw it working and here we are.
Also, since everything was so easily accessible, this was pretty much low hanging fruit, I'm even a bit concerned if there isn't such functionality already, but I haven't found it. Would be pretty bad if I've implemented something that's already there. 🤞
GitHub Issues
#1579