Question · NestJS course · Module 7: Testing
Testing NestJS controllers
When testing a NestJS controller, services should be:
Answer options
- Replaced with middleware
- Mocked to test the controller in isolation
- Connected to a real database
- Skipped in tests
You can check the correct answer by solving this task in the CodeWorlds game.