This is a POC using Jest and Supertest for API testing and Allure as reporting.
Run the dummy server
$ docker run -p 80:80 kennethreitz/httpbin
In another shell, run tests and reporting
$ git clone ...
$ cd ...
$ yarn install
$ # run tests
$ yarn test
$ # generate report
$ yarn allureReport
- Node v8.11.3
- Docker version 18.03.1
- Allure v2.7.0
I extended Jest expect
with .toMatchSchema()
. See jest-json-schema.