Newman reporter for OpenAPI coverage
npm install newman-reporter-openapi
├── path
| └── method
| ├── response
| ├── response
| └── response
└── path
└── method
├── response
└── response
`
It produces output like this:
!wide
$3
---
`console
npm install newman-reporter-openapi
or
npm install -g newman-reporter-openapi
`
$3
---
Add the report as a custom Newman reporter:
`console
newman --reporters openapi
`
You can include multiple Newman reporters like this:
`console
newman --reporters "cli,openapi"
`
The only required parameter for the OpenAPI reporter is the OpenAPI spec using --reporter-openapi-spec:
`console
--reporter-openapi-spec ./openapi.yaml
`
The reporter will check each Newman API call against the server list in your OpenAPI spec.
If the server isn't in that list, for local testing for example, you can specify it via --reporter-openapi-serverUrl
`console
--reporter-openapi-serverUrl http://127.0.0.1/3000
`
The reporter has three different report styles with different layouts. The default is wide.
`console
--reporter-openapi-reportstyle wide
--reporter-openapi-reportstyle tall
--reporter-openapi-reportstyle summary
``