DEV Community

Alexey Voinov
Alexey Voinov

Posted on

3

One tiny detail about The Saff Squeeze

The Saff Squeeze technique, introduced by Kent Beck few years ago is very nice. (Unfortunately, the original article has long gone, but there's an archived copy: Hit 'Em High, Hit 'Em Low) There's just one extra detail, worth noting. If you write a failing test, then on every failure, you'll need to check how exactly how it failed. Because if the reason for failure has changed, it means you did something wrong, and it's time to go one step back. But there's a trick. If you rewrite the test so it asserts on the wrong behaviour, it will be green (until you fix the code, of course). And what it means, is that your code is failing in a certain known way. No surprises. I find this variation to be a bit more convenient.

Qodo Takeover

Introducing Qodo Gen 1.0: Transform Your Workflow with Agentic AI

While many AI coding tools operate as simple command-response systems, Qodo Gen 1.0 represents the next generation: autonomous, multi-step problem-solving agents that work alongside you.

Read full post

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay