본문 바로가기
개발 프레임워크/NestJS

[NestJS] NestJS 실행 및 테스트 명령어

by minhyeok.lee 2023. 2. 5.
반응형

NestJS 개발모드, 워치모드, 생산모드, unit test, e2e test 등 명령어

명령어 모음

 

* 설치

$ npm install

 

* Nest JS CLI로 NEST JS 시작

$ npm i -g @nestjs/cli
$ nest new project-name

 

* 잘 설치되었는지 확인 ( nest 버전 확인 )

$ nest --version

 

* Nest.js 실행

개발모드( development ) 실행

$ npm run start

 

워치모드( watch mode ) 실행

$ npm run start:dev

 

생산모드( production mode ) 실행

$ npm run start:prod

 


* 테스트 실행

유닛 테스트 ( unit tests ) 실행

$ npm run test

 

End to eEnd tests ( e2e tests) 실행

$ npm run test:e2e

 

테스트 커버리지 ( test coverage ) 실행

$ npm run test:cov
반응형

댓글