•
Process isolation
•
FileSystem, Network
•
CPU/memory limits
Slide 11
•
Con guring multiple services simultaneously
•
Flexibility in creating test data or use-cases
•
Separation of production & test environments
•
Dynamic con guration of external mappings
•
Parallel deployments fi
fi
😓
Slide 12
testcontainers.org
Slide 13
Testcontainers •
Created 7 years ago
•
github.com/testcontainers/testcontainers-java
•
Uses docker-java API
•
Automatic Docker environment discovery
•
Automatic cleanup
Slide 14
Slide 15
We think it’s a useful default option for creating a reliable environment for running tests. … Our teams have consistently found this library of programmable, lightweight and disposable containers to make functional tests more reliable. https://www.thoughtworks.com/en-us/radar/languages-and-frameworks/testcontainers
Slide 16
Downloads
Slide 17
Unique IPs
Slide 18
Show me the code
Slide 19
Model: record Rating (String talkId, Integer value) {}
Slide 20
What’s next? Reusable containers Networks for more complex topologies Custom startup & waiting strategies Creating images on-the- y
fl
fi
Logs, les, commands, limits…