this post was submitted on 18 Jun 2025
360 points (96.9% liked)

Programmer Humor

38718 readers
136 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 6 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] qaz@lemmy.world 23 points 3 months ago (1 children)

Why not? Why doesn't the programmer want to test a container?

[–] davel@lemmy.ml 17 points 3 months ago (4 children)

True. Nothing beats running your unit tests in the actual container image that will be run in production.

[–] HiddenLayer555@lemmy.ml 10 points 3 months ago* (last edited 3 months ago) (2 children)

Race condition that only happens on the much faster production hardware: Allow me to introduce myself

[–] davel@lemmy.ml 7 points 3 months ago

Unit tests can’t win ’em all. That’s where things like integration tests, staging environments, and load testing come in.

The final layer of protection is the deployment strategy, be it rolling, canary, or blue-geen.

[–] Qaz@lemmy.ml 6 points 3 months ago

Or an issue that only appears when using ARM and not on my AMD64 dev machine

[–] bjoern_tantau@swg-empire.de 5 points 3 months ago

I mean, isn't that kind of the point of containers? To basically have the same environment everywhere.

[–] qaz@lemmy.world 5 points 3 months ago

Yeah, and it's useful to just check everything so you don't forget to add some essential system package for e.g. SSL, especially when working with Alpine.

[–] bizdelnick@lemmy.ml 1 points 3 months ago

Unit tests? No matter where you run them, and normally this is done by CI in a prebuilt container image, so you don't have to wait for "docker building". Acceptance tests must be run in an environment as close to production as possible, but that's definitely not a programmer's job.