Skip to content

Generates lightweight mocha smoke tests against HTTP APIs using swagger docs to inform validations.

License

Notifications You must be signed in to change notification settings

diosmosis/swagger-api-tester

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status

swagger-api-tester

Create lightweight smoke tests against HTTP APIs using swagger docs to inform validations.

Example

'use strict'

const Tester = require('swagger-api-tester')

describe('My API', function () {
  const test = new Tester('http://petstore.swagger.io/v2/swagger.json')

  test.post('/pet', pet).respondsWith(200, 'Pet')
  test.put('/pet', pet).respondsWith(200)

  test.get('/pet/20').respondsWith(200)
})

About

Generates lightweight mocha smoke tests against HTTP APIs using swagger docs to inform validations.

Resources

License

Stars

Watchers

Forks

Packages

No packages published