dev-resources.site
for different kinds of informations.
Integration Testing : Concept
Published at
7/26/2024
Categories
testing
beginners
typescript
integrationtesting
Author
jay818
Author
6 person written this
jay818
open
Integration Testing
What
In Integration Testing
we test how all the components work together, means unlike unit tests we don't have to mock out the services. We actually start all the services in the integration test and see how they work together.
Downside to this is that it is slower, as we have to start all the auxiliary services.
Here is a gist of what we have to do in the Integration Testing
How
To do the integration test we will use scripts and docker compose file.
-
docker-compose.yml file
- It will start all the services -
script file
- It will run docker compose file, wait for our DB , migrate the DB , Do the Intial Seeding and run all the tests.
run-integration.sh
docker-compose up -d
echo '๐ก - Waiting for database to be ready...'
# The below command will wait for the DB after that all the command run.
./wait-for-it.sh "postgresql://postgres:mysecretpassword@localhost:5432/postgres" -- echo '๐ข - Database is ready!'
npx prisma migrate dev --name init
npm run test
docker-compose down
# To run this file simply do `run-integration.sh` + you need to install wait-for-it.sh from github.
# curl https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh -o scripts/wait-for-it.sh
For All the Steps Visit - 100xdevs Integration Testing
Thanks
integrationtesting Article's
30 articles in total
Top 7 Best Integration Testing Tools for 2025
read article
Unit Test vs. Integration Test
read article
Choose Boring Releases
read article
The Struggle for Microservice Integration Testing
read article
Integration Testing in React: Best Practices with Testing Library
read article
Integration Testing in .NET: A Practical Guide to Tools and Techniques
read article
Testing Modular Monoliths: System Integration Testing
read article
Integration Testing : Concept
currently reading
The Complete Guide to Integration Testing
read article
End to End Testing vs Integration Testing โ 7 Key Differences
read article
How to improve test isolation in integration testing using Jest and testcontainers
read article
๐ Effortless Integration Tests with Testcontainers in Golang ๐งช
read article
Testcontainers - Integration Testing Using Docker In .NET
read article
Simple Mocks With Mockaco
read article
Ace Your Tests with Mocha, Chai, Sinon, and the Clean Architecture
read article
Testing Made Easy with Ava: No More Pulling Out Your Hair!
read article
Nock: The Purr-fect Tool for Testing HTTP Interactions!
read article
Take Your Mocktail Game to the Next Level with Sinon.js: The Fun Way to Test Your Code
read article
Get Your Chai Fix and Learn the Art of Assertions at the Same Time
read article
Mocha Testing: The Java in Your Script
read article
The ultimate guide to Jest: turn your testing woes into rainbows and unicorns
read article
Get Your Test On with Jasmine: The Happy Way to Ensure Quality
read article
Experience the joy of stress-free coding with unit and integration testing!
read article
Boost Your Productivity with These Top-Notch JavaScript Testing Libraries! (2022)
read article
What is Integration Testing?
read article
Automated integration testing - what features help?
read article
When should integration testing be automated?
read article
Azure Functions E2E Testing within GitHub Actions
read article
Differentiate between integration testing and system testing
read article
Beginners' Introduction to React Testing
read article
Featured ones: