jest-supertest-matchers

0.0.2 • Public • Published

jest-supertest-matchers

Code Climate Issue Count Build Status

Setup

import app from '../app';
import matchers from 'jest-supertest-matchers';
import request from 'supertest';
 
// inside tests
beforeAll(() => {
  expect.extend(matchers);
});
 
it('example', async () => {
  const res = await request(app).get('/');
  expect(res).toHaveHTTPStatus(200);
});

Readme

Keywords

none

Package Sidebar

Install

npm i jest-supertest-matchers

Weekly Downloads

11

Version

0.0.2

License

ISC

Unpacked Size

8.77 kB

Total Files

13

Last publish

Collaborators

  • mokevnin