Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,28 @@ Copy these files to your repo:
* `mongo-environment.js` - sets up `__MONGO_URI__` global variable
* `jest.config.js` - glues all together


Run
```sh
▶ yarn test
yarn run v1.5.1
$ jest --runInBand
Setup MongoDB Test Environment
PASS ./mongo-insert.test.js
Teardown MongoDB Test Environment
Setup MongoDB Test Environment
PASS ./mongo-aggregate.test.js

Test Suites: 2 passed, 2 total
Tests: 3 passed, 3 total
Snapshots: 0 total
Time: 1.721s
Ran all test suites.
Teardown mongod
Teardown MongoDB Test Environment
✨ Done in 3.30s.
```

NPM dependencies:

* [mongodb-memory-server](https://github.com/nodkz/mongodb-memory-server) - required for Jest Async Test Environment
Expand Down