frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Ask HN: How much emphasis to put on unit testing and when?

3•theturtlemoves•1h ago
I'm wondering if a shift has occurred. When I started as a junior software engineer, over a decade ago, I learned about unit testing, integration testing, system testing. The whole codebase we worked on was thoroughly unit tested, and had layers of integration tests and system tests as well. I've worked for other employers since and in some cases any kind of automated testing was completely absent. Still, the message I got when reading and keeping up with best practices was: unit test ALL the things!

I've personally found that when the architecture of the system is not mature yet, unit tests can get in the way. Terribly so. Integration tests or system tests to assert behavior seem the starting point in this and other scenario's, including when there are no tests at all yet.

I've recently read a statement about letting go of a strict "unit test everything" mindset and go for integration tests instead. I'm thinking it probably depends, as with everything, on the type of system you're working on, the maturity of the system, the engineers' experience with automated testing, etc.

I'd be interested to learn when each type of testing helps you and when it gets in the way (and what it gets in the way of).

Comments

rvz•1h ago
The moment the software is in production, making a lot of money and is stable, I then add lots of tests (both unit and integration) to prevent a $1,000 issue turning into a $100,000 problem later down the line.

Instead of testing everything to being perfect, 100% test coverage and never releasing and the company questioning why the deadlines were missed for the project because of testing dogma.

> I've personally found that when the architecture of the system is not mature yet, unit tests can get in the way. Terribly so. Integration tests or system tests to assert behavior seem the starting point in this and other scenario's, including when there are no tests at all yet.

Totally agree.

aurareturn•21m ago
I don't write any unit tests. Instead, I only do integration/system tests.

At the end of the day, I need to know that the system works and does what it is suppose to do. Unit tests adds too much complexity in my opinion and isn't worth it.

The Enclosure feedback loop: how LLMs sabotage by privatizing a public good

https://michiel.buddingh.eu/enclosure-feedback-loop
1•internet_points•47s ago•0 comments

High Performance LLM Inference Operator Library from Tencent

https://github.com/Tencent/hpc-ops
1•polyrand•47s ago•0 comments

Pavel Durov: "You'd have to be braindead to believe WhatsApp is secure in 2026"

https://twitter.com/durov/status/2015854422866469222
2•martinlaz•1m ago•0 comments

For Our Machine Friends

https://toasterdump.com/2026/01/18/for-our-machine-friends/
1•xxyxx•4m ago•0 comments

Blocking Claude

https://aphyr.com/posts/403-blocking-claude
1•Tomte•5m ago•0 comments

How to audit your LinkedIn profile

1•semihayat•6m ago•0 comments

Il dominio della narrazione, ovvero spegnere il cervello è bello

https://cinemanuele.substack.com/p/il-dominio-della-narrazione-ovvero
1•grouchoromano•9m ago•0 comments

Show HN: RustyBoard – The largest collection of active Rust jobs and analytics

https://rustyboard.com
1•louispog•11m ago•0 comments

Anti-pop and an alien sigil: how Aphex Twin overtook Taylor Swift

https://www.theguardian.com/music/2026/jan/27/aphex-twin-taylor-swift-soundtrack-to-gen-z-life-on...
3•quakeguy•13m ago•0 comments

The Complete SEO Guide for SaaS Startups in 2026

https://kitful.ai/blog/the-complete-seo-guide-for-saas-startups-in
1•eashish93•14m ago•0 comments

Digital non-Foster-inspired electronics for broadband impedance matching

https://www.nature.com/articles/s41467-024-48861-6
1•teleforce•15m ago•0 comments

Say no to linked lists as a "standard" data structure (2019)

https://rust-unofficial.github.io/too-many-lists/#an-obligatory-public-service-announcement
1•mefengl•17m ago•0 comments

mcelog: Logs and accounts machine checks on modern x86 Linux systems

https://www.mcelog.org/
1•teleforce•18m ago•0 comments

Show HN: Takes – A Daily Chess Solitaire Game

https://takes.labs.clevergoat.com
1•juannyp•23m ago•0 comments

You can't open 2 cameras with getUserMedia at same time on Android and iOS

https://tony-xlh.github.io/getUserMedia-multiple-camera/
1•julienreszka•26m ago•1 comments

GIC, Sequoia, Index purchase Notion shares in private tender offer

https://www.notion.com/blog/gic-sequoia-index-purchase-notion-shares
1•doppp•26m ago•0 comments

Clawdbot Is Now Moltbot

https://twitter.com/moltbot/status/2016058924403753024
2•chl•28m ago•0 comments

XAgent CLI – AI assistant that can control your mouse and keyboard

https://github.com/xAgent-AI/xagent
1•ouyangwenli•28m ago•1 comments

One Hundred Years of Television

https://diamondgeezer.blogspot.com/2026/01/tv100.html?m=1
1•beardyw•29m ago•0 comments

Show HN: DNS Monitor

https://monitordns.app/
1•rsc-dev•32m ago•0 comments

Software Pump and Dump

http://tautvilas.lt/software-pump-and-dump/
2•brisky•34m ago•0 comments

Two empty chairs: why "obvious" decisions keep breaking production

https://read.perspectiveship.com/p/perspective-taking
1•birdculture•34m ago•0 comments

Things got too easy with AI

https://gusarich.com/blog/things-got-too-easy
1•Gusarich•35m ago•0 comments

Glass Core Substrates and Glass Interposers: Advanced Packaging for AI and HPC

https://www.microwavejournal.com/articles/44910-glass-core-substrates-and-glass-interposers-new-g...
1•teleforce•36m ago•0 comments

What happens to the human body in 49C heat? Australians are finding out

https://www.theguardian.com/australia-news/2026/jan/27/what-happens-to-the-human-body-in-49c-heat...
2•beardyw•37m ago•0 comments

Voice-first dating app that matches you in 4 days

https://voicevibe.dating/
2•evercrestaimee•37m ago•2 comments

Bop Spotter

https://walzr.com/bop-spotter
1•mattmark•39m ago•1 comments

South Korea's Edenlux set for U.S. debut of eyestrain wellness device

https://techcrunch.com/2026/01/26/south-koreas-edenlux-set-for-u-s-debut-of-eye-strain-wellness-d...
2•plun9•42m ago•0 comments

Automating Image Compression

https://www.ramijames.com/thoughts/on-automating-image-compression
8•ramijames•44m ago•0 comments

Shorlabs: Deploy back ends without the hassle. (OSS Alternative to Render)

https://www.shorlabs.com/
10•shorlabss•44m ago•0 comments