Service for handling cars, their data and comments
- Node 16
- ApolloServer
- Typescript
- TypeGraphQL
- TypeORM
- ClassValidator
- Mocha + Sinon + Chai
- SuperTest
- ESLint
- Config
- Winston
- Nodemon
- TSNode
- NPM
- Nodemailer
- Installed Node 16
- Installed NPM
- Configured local or remote MySQL Server
-
Install Node 14
-
Go to package.json and install dependencies
npm i
-
Configuration
Configuration (server, database, mail etc.) uses default values and they can be changed using environment variables (check
config/default.js
file) -
Go to docker compose file and run images used for local development
- Run all images:
docker compose up -d
- Run specified images:
docker compose up nodemailer -d
- Run all images:
-
Run unit tests
- Linux/Mac:
npm run test:unit
- Windows:
npm run test:unit:windows
- Linux/Mac:
-
Run API tests
- Linux/Mac:
npm run test:api
- Windows:
npm run test:api:windows
- Linux/Mac:
-
Run integration tests (they require local environment images started with Docker)
- Linux/Mac:
npm run test:integration
- Windows:
npm run test:integration:windows
- Linux/Mac:
-
Start local server
- Linux/Mac:
npm run start:dev
- Windows:
npm run start:dev:windows
- Server starts at
http://localhost:4000/
- Default GraphQL endpoint is
POST
http://localhost:4000/graphql
- Linux/Mac: