
About Testcontainers
Testcontainers is an open source library that starts throwaway instances of databases, message brokers and browsers in Docker. Tests get real dependencies instead of mocks.
What it does
You define the containers a test needs in code. When the test run starts, the containers are created, and they are removed afterwards, so each run begins from a known state. Libraries exist for many languages, including Java, Go, .NET, Node.js, Python, Rust and PHP. Browser containers compatible with Selenium are also available for UI tests.
Key features
- Databases, brokers and browsers in containers
- A clean state for each test run
- Modules for more than 50 services
- Selenium compatible browser containers
Who it's for
Backend and full stack teams who want integration tests against real services without complex setup on each developer machine.
Pricing and good to know
The Java library is open source under the MIT license. Docker must be installed and running on the machine or CI runner where the tests run. The project lists many language implementations, so teams can use the same approach across services.
Highlights
- Run real databases and brokers in containers
- Containers created and removed per test run
- Ready-made modules for more than 50 services
- Selenium compatible browser containers for UI tests












