yarn chai-openapi-response-validator 0.2.0
0.2.0 / 30 Jul 2019

latest releases: 0.14.2, 0.14.2-alpha.0, 0.14.1...
4 years ago

Added simple Chai support for asserting that HTTP responses satisfy an OpenAPI spec. Specifically, added the expect(res).to.have.status(200).and.satisfyApiSpec assertion.

Features

  • Validates the status and body of HTTP responses against an OpenAPI spec
  • Easily load your OpenAPI spec just once in your tests
  • Supports OpenAPI 2 and 3
  • Supports OpenAPI specs in YAML and JSON formats
  • Supports $ref in response schemas (i.e. $ref: '#/definitions/ComponentType/ComponentName')
  • Informs you if your OpenAPI spec is invalid

Don't miss a new chai-openapi-response-validator release

NewReleases is sending notifications on new releases.