r/java • u/raisercostin • Jun 01 '24
What java technology (library, framework, feature) would not recommend and why?
Inspired by https://www.reddit.com/r/java/s/e2N1FqMOJg
165
Upvotes
r/java • u/raisercostin • Jun 01 '24
Inspired by https://www.reddit.com/r/java/s/e2N1FqMOJg
5
u/DelayLucky Jun 01 '24 edited Jun 01 '24
Only if these questions are out of scope for your test:
Am I sending the right request to the service for what I'm trying to do, with all required fields set correctly ? (e.g. charge a credit card).
Am I interpreting the response correctly? Is the value I expect coming in this particular field?
And if this unit test isn't concerned of these aspects, you better make sure there are tests that do verify them.
Too often I've seen people just assuming that they must be interacting with a service in the right way. And bugs often come out of those cracks of the system becasue what are the odds that two teams of different engineers happen to align without talking to each other once?
"Integration tests", "unit tests", they are just names. At the end of day you want your production to work as expected. Customers don't want to hear "I've coded my client code according to the document of this dependent service, it's their fault the system didn't work out".