1.1.0 • Published 2 years ago

@konecty/jest-doc-reporter v1.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Konecty

npm shield

Jest Docs Reporter

Jest test results processor for generate a list of suites and test cases

Installation

$ yarn add --dev @konecty/jest-doc-reporter

Usage

Configure Jest to process the test results by adding the following entry to the Jest config (jest.config.json):

"reporters": [
	"default",
	["@konecty/jest-doc-reporter", {
		"title": "Test Report",
        "outputPath": "./docs",
		"sort": "asc",
	}]
]

As you run Jest from within the terminal, a file called index.md will be created within your outputPath or root folder containing information about your tests.

Node Compatibility

npm shield

This plugin is compatible with Node version ^16.0.0

Configuration

Please note that all configuration properties are optional.

PropertyTypeDescriptionDefault
titleSTRINGThe title of the document. This string will also be outputted on the top of the page."Docs"
logoSTRINGPath to a logo that will be included in the header of the reportnull
outputPathSTRINGThe path to where the plugin will output the HTML report."./"
sortSTRINGSorts the test results alphabeticaly using "asc", "desc" or "none""none"
filterRegexSTRING or REGEXRemove test result that matches the patternundefined
oneFilePerSuiteBOOLEANSplit results one file per suitefalse