Skip to content

caioagiani/nodejs-nlw4

This branch is 1 commit ahead of main.

Folders and files

NameName
Last commit message
Last commit date
Feb 28, 2021
Feb 28, 2021
Feb 28, 2021
Feb 27, 2021
Feb 28, 2021
Feb 27, 2021
Feb 27, 2021
Feb 28, 2021
Mar 2, 2021
Feb 27, 2021
Mar 2, 2021
Feb 27, 2021
Mar 16, 2023
Feb 27, 2021
Mar 1, 2021
Feb 27, 2021

Repository files navigation

nextlevelweek

NLW#4 | Nodejs

languages-count languages-top repo-size last-commit

Project developed during the Nodejs trail in the 4th edition of Next Level Week provided by [Rocketseat].

Technologies used

Express TypeScript NodeJS PostgreSQL Docker TypeORM Eslint Prettier jest

Start application

# Clone this project
$ git clone git@github.com:caioagiani/nodejs-nlw4.git

# Open folder
$ cd nodejs-nlw4

# Install dependencies
$ yarn install

# Set up variable environments
$ cp .env.example .env

# Execution permission arrow in script
$ sudo chmod +x src/scripts/database.sh

# Start database postgress with docker
$ yarn dev:db

# Create database table
$ yarn typeorm migration:run

# Run application
$ yarn dev

# Run tests
$ yarn dev:test

Tests

caio-agiani in nlw4 on -> master  yarn dev:test
yarn run v1.22.5
$ NODE_ENV=test jest --setupFiles dotenv/config --detectOpenHandles --forceExit
 PASS  __tests__/Mail.test.ts (6.397 s)
 PASS  __tests__/Answer.test.ts
 PASS  __tests__/Nps.test.ts
 PASS  __tests__/Survey.test.ts
 PASS  __tests__/User.test.ts

Test Suites: 5 passed, 5 total
Tests:       13 passed, 13 total
Snapshots:   0 total
Time:        13.429 s
Ran all test suites.
Done in 15.43s.

Contact