Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
๐ซ [DMVM-220]
๋ณ๊ฒฝ ์ฌํญ์ ๋ํ ์ค๋ช
E2E (End-to-End) ํ ์คํธ๋ฅผ ์ํ ์ค์ ์ ์ฒ๋ฆฌํ์์ต๋๋ค.
E2E ํ ์คํธ๋ฅผ ์ํ์ฌ
TestContainers๋ฅผ ํ์ฉํ์ฌ ์๋์ ๊ฐ์ ๋ถ๋ถ์ ์ปจํ ์ด๋ํ ํ์์ต๋๋ค.
PostgreSQL ๊ฐ์ ๊ฒฝ์ฐ pg-mem์ด ์กด์ฌํ๋ PostGIS๋ ์ฌ์ฉํ ๊ฐ๋ฅ์ด ๋ค๋ถํ์ฌ ๋๊ฐ ๋ชจ๋ ์ค์ ํ์์ต๋๋ค.
ํ ์คํธ ๋ฐฉ๋ฒ
yarn run test
๋ณ๊ฒฝ๋ ํ๊ฒฝ
@testcontainers/redis
@testcontainers/postgresql
๋ผ์ด๋ธ๋ฌ๋ฆฌ ์ถ๊ฐ
์ฐธ๊ณ ์ฌํญ
ํ ์คํธ๊ฐ ๋ชจ๋ ์๋ฃ๋์ด๋ jest๊ฐ ์ข ๋ฃ๋์ง ์๋ ํ์์ด ์์ต๋๋ค.
์กฐ์น๋ฅผ ์ทจํด์ผ ํ๋ ์ผ์์ ์ผ๋ก Jest CLI ์ต์ ์ ํตํด ์์ ์กฐ์นํ์์ต๋๋ค. (package.json)
ํด๋น ํ์์ jest --detectOpenHandles --forceExit ๋ก CLI ์ต์ ์ ์ ์ฉํ๋ฉด ์ข ๋ฃ๋ฉ๋๋ค.