limberest

1.0.15 • Public • Published

Limberest Logo

REST API Automated Testing

Install

npm install --save limberest

Usage

Path-Style Locations:

  • If using Node, point to file system directories.
  • If in browser, point to local storage paths.

URL-Style Locations: (For options.location, options.expectedResultLocation)

  • Point to GitHub repository relative location.

Example:

const limberest = require('../lib/limberest');

// Note testsLoc on file system allows synchronous reads.
const testsLoc = '../../limberest-demo/test';
var values = limberest.loadValuesSync(testsLoc + '/limberest.io.values');
var group = limberest.loadGroupSync(testsLoc + '/movies-api.postman');

var request = group.getRequest('GET', 'movies?{query}');

values = Object.assign({}, values, {query: 'year=1935&rating=5'});

var options = {
  location: testsLoc,
  expectedResultLocation: testsLoc + '/results/expected',
  resultLocation: testsLoc + '/results/actual',
  debug: true,
  responseHeaders: ['content-type']
};

request.run(options, values)
.then(response => {
  request.verify(values);
})
.catch(err => {
  console.log(err);
});

Full Documentation:

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.15
    2
    • latest

Version History

Package Sidebar

Install

npm i limberest

Homepage

limberest.io

Weekly Downloads

2

Version

1.0.15

License

MIT

Last publish

Collaborators

  • oakesville