The tree printer continues hierarchy connection lines past terminal nodes as shown below:
โ โโ A stack
โ โ โโ is instantiated with new Stack() โ
โ โ โโ when new
โ โ โ โโ throws EmptyStackException when popped โ
โ โ โ โโ throws EmptyStackException when peeked โ
โ โ โ โโ is empty โ
โ โ โ โโ after pushing an element
โ โ โ โ โโ it is no longer empty โ
โ โ โ โ โโ returns the element when peeked but remains not empty โ
โ โ โ โ โโ returns the element when popped and is empty โ
โ โโ A stack
โ โ โโ is instantiated with new Stack() โ
โ โ โโ when new
โ โ โโ throws EmptyStackException when popped โ
โ โ โโ throws EmptyStackException when peeked โ
โ โ โโ is empty โ
โ โ โโ after pushing an element
โ โ โโ it is no longer empty โ
โ โ โโ returns the element when peeked but remains not empty โ
โ โ โโ returns the element when popped and is empty โ
Will be implemented with the caveat that the tree is no longer printed immediately. The two other details modes, namely FLAT and VEROSE, will remain as-are.
Getting closer: https://travis-ci.org/junit-team/junit5/jobs/207683435#L519
@sormuras Looks nice!
Thanks for the thumbs.
What do you think of the aligned/grouped test report entry rendering: https://travis-ci.org/junit-team/junit5/jobs/207892944#L612 ?
@sormuras I like the way the test report's date is inset from the test name which implies another level of nesting in the hierarchy. In fact I think it's better without lines. There's one other possibility to include in your demo ... a test that has multiple single-line report entries (which could potentially have different timestamps).
I personally like aligning the separators when showing key/value data because it makes it more like a table but I wouldn't hold this issue up for that. Using even more indentation for the multi-value report entry shows that those items are all subordinate to the timestamp too. I think you've gone above and beyond the call of duty on the test tree printer!
[...] a test that has multiple single-line report entries (which could potentially have different timestamps).
Current (and outdated) iteration already covers that in a test. https://github.com/junit-team/junit5/compare/refactor_tree_printing_listener#diff-bcdd220ee20a4cdae2c4835d9e21e65bR163 May enhance the documentation demo as well.
I personally like aligning the separators when showing key/value data [...]
Me too. But having keys with different lengths will shuffle the lines around again.
Looks good!
Do you think an optional caption for a test report set is worth the effort? See https://github.com/junit-team/junit5/pull/711/files#r104756183
Probably not right now. Shall we create a separate issue?
M5 or 5.1. Fine with me. Created #712.
Most helpful comment
Getting closer: https://travis-ci.org/junit-team/junit5/jobs/207683435#L519