1.0.2 • Published 1 year ago
hein-plugin-supertest v1.0.2
hein-plugin-supertest
Plugin for hein that adds assertions for supertest.
Installation
import { use } from 'hein';
import { supertestPlugin } from 'hein-plugin-supertest';
use(supertestPlugin);
Usage
status
expect(response).to.have.status(200);
json
Check that the response content type is json
expect(response).to.be.json();
xml
Check that the response content type is xml
expect(response).to.be.xml();