r/node • u/ahmedshahid786 • 10h ago
How do you guys test your backends in production?
I'm a junior engineer working in a small team. We've been building a product for around 8 months using Express.js, and shipping features has always been our biggest priority.
One thing I've been noticing lately is that as our codebase grows, shipping a new feature occasionally breaks something that was previously working. Sometimes we don't even realize it until a user reports it.
We have a handful of basic tests, but nothing comprehensive enough to give us confidence when shipping new features or refactoring existing code.
I want to change that.
I've heard about unit testing, integration testing, end-to-end testing, smoke testing, and load testing, but my practical experience beyond basic tests is pretty limited.
I'd love to understand:
- What kinds of tests do you actually write for your backends?
- How do you decide what to test and what not to test?
- How do you introduce testing into an existing codebase without slowing down development significantly?
- What tools and frameworks do you use?
- How do you structure your testing suite and integrate it into CI/CD?
I'd particularly appreciate practical resources, open-source repositories with good testing practices, or engineering articles that demonstrate how these things are done in real projects.
I don't want to write tests just to increase a coverage percentage. I want to reach a point where we can ship features and refactor code without constantly worrying about what we might have broken.
Would love to hear how you guys approach this in your daily work.