Skip to content

becheran/go-testreport

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Test Report

Pipeline Status Go Report Card PRs Welcome License

Generate a markdown test report from the go json test result.

Matches perfectly with github job summaries to visualize go test results:

ReportExample

The default output sorts the tests to show failing and slow tests at the top.

Install

Install via the go install command:

go install github.com/becheran/go-testreport@latest

Or use the pre-compiled binaries from github releases.

Run

Will use the standard input and return the result into a file:

go test ./... -json | go-testreport $GITHUB_STEP_SUMMARY

Customize by providing a own template file. See also the default markdown template. With the vars options custom values can be passed to the template from the outside:

go test ./... -json | go-testreport -template=./html.tmpl -vars="Title:Test Report Linux" $GITHUB_STEP_SUMMARY