Skip to content
This repository has been archived by the owner on Feb 5, 2022. It is now read-only.

Testing

Alejandro Recalde edited this page Mar 9, 2021 · 3 revisions

Integration Tests

Located in test/api folder
Supertest and Jest are used
Steps in every integration test:

  1. Before: spin up an in-memory test db (SQLite) and seed it by running some migrations
  2. Make a request to the api using supertest's optimized test environment and make some relevant assertions
  3. After: close DB connection, so it's automatically deleted as every in-memory db
Clone this wiki locally