Skip to content

Commit

Permalink
use testcontainers for e2e testing on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
f-w committed Dec 10, 2024
1 parent ca0746e commit 1ac00cc
Show file tree
Hide file tree
Showing 6 changed files with 1,040 additions and 36 deletions.
2 changes: 2 additions & 0 deletions docs/docs/miscellaneous/developer-notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ _NotifyBC_ uses [Jest](https://jestjs.io/) test framework bundled in NestJS. To

Github Actions runs tests as part of the build. All test scripts should be able to run unattended, headless, quickly and depend only on local resources.

To run automated testing on Windows, Docker Desktop needs to be running.

### Writing Test Specs

Thanks to [supertest](https://github.com/visionmedia/supertest) and [MongoDB In-Memory Server](https://github.com/nodkz/mongodb-memory-server), test specs can be written to cover nearly end-to-end request processing workflow (only _sendMail_ and _sendSMS_ need to be mocked). This allows test specs to anchor onto business requirements rather than program units such as functions or files, resulting in regression tests that are more resilient to code refactoring.
Expand Down
Loading

0 comments on commit 1ac00cc

Please sign in to comment.