Skip to content

Latest commit

 

History

History
57 lines (39 loc) · 1.13 KB

README.md

File metadata and controls

57 lines (39 loc) · 1.13 KB

Node API TDD

In the node ecosystem, We haven't been able to find an article describing the way we prefer to practice TDD internally. We are describing how we prefer to practice TDD in node in an article you can find here.

Prerequisites

You will need node to be installed on your computer. You can download it here.

Installing

npm install

Create .env and .env.test files with your database credentials in them like this:

.env

DB_NAME=node_tdd
DB_USER=your_db_username
DB_PASSWORD=your_db_password
DB_HOST='127.0.0.1'
DB_DIALECT=postgres

.env.test

DB_NAME=node_tdd_test
DB_USER=your_db_username
DB_PASSWORD=your_db_password
DB_HOST='127.0.0.1'
DB_DIALECT=postgres

Running the server

node server.js

Running the tests

npm run tests

Authors

License

This project is licensed under the MIT License - see the LICENSE.md file for details