mocking and abstraction in testing

Abstraction and Testing – Mocks

Abstraction is one of the founding principles of software. In this post I describe how mocks break abstraction and its effect on testing.

Abstraction in testing

Abstraction and Testing – Intro

Abstraction is one of the founding principles of software. It allows us to simplify ideas, code and usage. It also impacts testing directly.

“Clean Tests” – Webinar Recording

Clean tests are readable, maintainable, and helpful in case of failure- themselves, or their brothers. This webinar describes clean code and tests.

refactoring without a net

Refactoring Without A Net – Webinar Recording

What exactly is refactoring? Is it just changing code? What does “not changing functionality” really means? Well, you’ve come to the right place. I’ve got just the webinar for you. And not only that, I’m going to show you how… Continue Reading…

On The Edge

A lot of people use the term “Edge Case”. I find it offensive. Ok, not really, but there’s a misuse of the term. While we’re at it, let’s throw in negative cases, happy and unhappy paths, etc. We tie in… Continue Reading…

Where do bugs come from?

People ask me: Are we ever going to get rid of bugs? And I tell people: No. And then they pull out their machine guns and things get messy. But why is that? Are we really doomed for fighting bugs… Continue Reading…

Clean Code is a Social Activity

I do a lot of clean code workshops these days; it seems that, finally, clean code gets the respect it deserves. Clean tests too. There’s one point I make (a few times even) during the workshop: While I give a… Continue Reading…

Gil Zilberfeld describes his upcoming talk "Spock" on the unit testing framework that allows clean code and readable tests.

“Spock” Talk at ExpoQA 2019, Madrid

“Why do we need another testing framework”? Next week, I’m giving a brand new talk at the expoQA conference in Madrid. It’s on Spock – the unit testing framework, not the Starfleet commander. The first question I need to answer… Continue Reading…

Gil Zilberfeld explains how testability is impacted by developer decisions like dependency injection

“Dependency Injection” Talk – The Slides

Had a great fun at the meetup, as always. And the fun part was that my message resonated a lot stronger after the lightning talk before mine, where the speaker talked about how the developers chose a technique that made… Continue Reading…

Gil Zilberfeld explains how clean code should read and explain the relationship between types. Using class inheritance maybe

Clean Code: The Rectangle and the Square – Part II

Last time, in the first post in my new clean code series, we discussed how I torment my students with the ol’ Square and Rectangle trick in my Clean Code course, talking about Liskov Substitution Principle (LSP). At the end… Continue Reading…

Copyright Gil Zilberfeld, 2025