go-test-report
go-test-report copied to clipboard
Suggestion: Export to Markdown
It would be amazing if this repo would also support exporting to Markdown so that PR comments and GitHub issue can be created from the reports.
@mowies Added a patch to add --markdown, hopefully that is what you were looking for
@afbjorklund Amazing! I just checked out the PR! One thing maybe to add: For bigger test suites, the report gets super long for me. Is it somehow possible to provide an option to pass in my own custom markdown template? I would like to put in a more condensed template where every test is just a single line or even a table with just test name and a checkmark or a cross.
There is now a --template parameter as well:
go test -json | ./go-test-report --markdown --template short_report.md.template
test_report.md
go-test-report
Total: 17
✓ TestGenerateReport
✓ TestGroupOutputFlag
✓ TestGroupOutputFlagIfMissingValue
✓ TestGroupSizeFlag
✓ TestGroupSizeFlagIfMissingValue
✓ TestParseSizeFlagIfHeightValueIsNotInteger
✓ TestParseSizeFlagIfMalformedSize
✓ TestParseSizeFlagIfValueIsNotInteger
✓ TestParseSizeFlagIfWidthValueIsNotInteger
✓ TestReadTestDataFromStdIn
✓ TestSameTestName
✓ TestSizeFlag
✓ TestSizeFlagIfMissingValue
✓ TestSizeFlagWithFullDimensions
✓ TestTitleFlag
✓ TestTitleFlagIfMissingValue
✓ TestVersionCommand
✓ Passed: 17 | ‐ Skipped: 0 | ✗ Failed: 0
Awesome! This is exactly what I needed
was this deprecated by something else? Why didn't this ever get merged?
- https://github.com/vakenbolt/go-test-report/pull/39#issuecomment-997683958
There have been no new go-test-report releases in 2022, or in 2023.
So forking is the right answer then, I suppose, unless you are aware of another ready made solution that exports to markdown?
Plenty of tools write markdown, but not exactly similar for go test no.
- #60