Integration Testing
Integration testing checks whether two or more software parts work together across a real boundary, such as an application talking to its database, message broker, file system, or another service.
itSoftware engineering | OpenSkills.info
Intro
Integration Testing
Integration testing checks whether multiple software parts cooperate across a boundary. A test starts a system under test, connects it to one or more collaborators, triggers behavior through a real entry point, and observes the result. The boundary might be a database driver, an HTTP API, a message broker, a file system, or framework wiring.
That scope distinguishes an integration test from a unit test. A unit test isolates a small piece of logic and commonly replaces infrastructure with a test double. An integration test keeps the boundary under examination real enough to expose mismatched schemas, serialization errors, configuration mistakes, and incorrect assumptions about another component. It is usually slower and more expensive to diagnose because more moving parts participate.
Integration testing is also narrower than end-to-end testing. An end-to-end test follows a complete user or business flow through the deployed system. A focused integration test can exercise one application boundary without a browser, production network, or every downstream service. Teams use both scopes, but each test should state which boundary it proves.
The test path
A useful integration test has five parts:
- System under test: the application, service, repository, or component whose behavior is being checked.
- Entry point: a public API, command, event, or method that triggers the behavior.
- Collaborator: a real dependency, controlled emulator, or test double on the other side of the selected boundary.
- Fixture: the configuration and data required to create a known starting state.
- Observation: an externally visible result, such as a response, stored record, published message, or file.
Continue the course
This section is part of the paid course.
See pricing to subscribe, or log in if you already have access.
Where this skill leads
Relevant careers
See how this topic contributes to broader role-level skill maps.
Sources
- https://learn.microsoft.com/en-us/aspnet/core/test/integration-tests
Supports
- Integration tests cover multiple components and supporting infrastructure
- Unit tests isolate components while integration tests take longer and require more processing
- System under test terminology, public request flow, test hosts, test databases, seeding, and suite separation
- Quiz answers about scope, cost, fixtures, state, and the system under test
- https://martinfowler.com/articles/practical-test-pyramid.html
Supports
- Narrow integration tests exercise application boundaries such as databases, files, and remote services
- A database test starts the dependency, triggers behavior, and reads the result
- Local dependencies and test doubles can improve independence and feedback speed
- Test portfolios use fewer tests as scope and cost increase
- https://docs.spring.io/spring-boot/reference/testing/testcontainers.html
Supports
- Testcontainers manages services in containers for integration tests against real backend software
- Application configuration can receive container connection details for test execution
- https://testcontainers.com/
Supports
- Test dependencies can be defined as code, created for tests, and removed afterward
- Containerized databases, brokers, and web services support data-layer and application integration tests
- Disposable dependencies provide known state across supported language ecosystems
- https://java.testcontainers.org/features/startup_and_waits/
Supports
- Container startup and service readiness require explicit wait strategies and bounded timeouts
- Quiz answer about meaningful readiness checks
- https://docs.github.com/en/actions/tutorials/use-containerized-services/use-docker-service-containers
Supports
- CI jobs can provision fresh database, cache, or web-service containers for integration tests and remove them after the job
- Service containers require explicit networking and port configuration depending on job placement
- https://docs.pact.io/
Supports
- Consumer-driven contract tests check that service interactions remain compatible
- Contract testing complements rather than proves all deployment and end-to-end behavior
- Quiz answers about the limits of doubles and contract tests
- https://wiremock.org/docs/
Supports
- WireMock simulates HTTP dependencies with request matching, controlled responses, faults, and verification
- A test double proves configured SUT behavior rather than current behavior of a real provider
- https://wiremock.org/docs/faq/
Supports
- WireMock core is open source and free, with a hosted managed service available
- Landscape licensing and pricing classification for WireMock
- https://www.mock-server.com/mock_server/getting_started.html
Supports
- MockServer tests proceed through expectation setup, scenario execution, and request verification
- Awesome Links rationale and Landscape placement for MockServer
- https://www.mock-server.com/proxy/verification.html
Supports
- MockServer verifies recorded requests, responses, counts, and sequences
- Quiz answer about interaction verification
- https://learning.postman.com/docs/tests-and-scripts/test-apis/integration-testing/
Supports
- Postman collections can exercise API interactions and multi-request data flows
- Landscape placement for Postman
- https://docs.localstack.cloud/
Supports
- LocalStack provides a local cloud emulator for cloud-application integration testing
- Landscape placement for LocalStack
- https://docs.localstack.cloud/aws/getting-started/quickstart/
Supports
- A local cloud fixture can host infrastructure and an automated integration-test suite
- Reference-link rationale for the integration-testing quickstart
- https://smartbear.com/product/ready-api/
Supports
- ReadyAPI runs functional API tests across REST, SOAP, Kafka, JDBC, and JMS and integrates with CI systems
- Landscape placement for ReadyAPI
- https://docs.karatelabs.io/
Supports
- Karate supports API requests, assertions, database and message testing, mocks, and CI execution
- Landscape placement and open-source classification for Karate
- https://github.com/sindresorhus/awesome
Supports
- The canonical index identifies the curated awesome-testing list as the software-testing list
- https://github.com/TheJambo/awesome-testing
Supports
- The service-virtualization section identifies WireMock, MockServer, and Beeceptor as testing ecosystem tools
- https://beeceptor.com/docs/
Supports
- Beeceptor provides mock endpoints for controlled API dependency behavior
- Awesome Links rationale and Landscape placement for Beeceptor
