This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Testing with mocha in Node it's enough just to create the file with ending *test.js | |
| const expect = require('expect'); | |
| // custom matcher (https://medium.com/@andrei.pfeiffer/jest-matching-objects-in-array-50fe2f4d6b98) | |
| // checks if array contains given object | |
| expect.extend({ | |
| toContainObject(received, argument) { | |
| const pass = this.equals( | |
| received, | |
| expect.arrayContaining([expect.objectContaining(argument)]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #uruchamiam mongodb z danymi z folderu home /mongo-data | |
| mongod --dbpath ~/mongo-data | |
| #przykład | |
| mongod --dbpath ~/PROGRAMOWANIE/mongo-data/ |