Publications de Pierre Top

Software Craftsmanship

The case for writing (isolated) test cases – #2

What is legacy code? "Code without tests is bad code. It doesn't matter how well written it is; it doesn't matter how pretty or object-oriented or well-encapsulated it is. With tests, we can change the behavior of our code quickly and verifiably. Without them, we really don't know if our code is getting better or worse.” “To me, legacy code is simply code without tests.” Michael Feathers, Working Effectively with Legacy Code "The code has no tests." Such a report often strikes me as a…

Lire la suite
Software Craftsmanship

Défense et illustration des test isolés – #2

Qu’est-ce que le code legacy ? "Le code sans test est du mauvais code. Peu importe qu’il soit bien écrit; peu importe à quel point il est élégant, orienté-objet ou encapsulé. Avec des tests, nous pouvons changer le comportement de notre code rapidement et de manière fiable. Sans eux, nous ne pouvons pas réellement savoir si l’état du code s’améliore ou empire.” “En ce qui me concerne, le code legacy est simplement du code sans tests.” Michael Feathers, Working Effectively with Legacy Code "Ce code…

Lire la suite
Software Craftsmanship

Défense et illustration des tests isolés – #1

"There is hardly anything in the world that someone cannot make a little worse and sell a little cheaper, and the people who consider price alone are that person’s lawful prey. It’s unwise to pay too much, but it’s worse to pay too little. When you pay too much, you lose a little money — that is all. When you pay too little, you sometimes lose everything, because the thing you bought was incapable of doing the thing it was bought to do. The common…

Lire la suite
Software Craftsmanship

The case for writing (isolated) test cases – #1

Should we write unit tests or integration tests ? "There is hardly anything in the world that someone cannot make a little worse and sell a little cheaper, and the people who consider price alone are that person’s lawful prey. It’s unwise to pay too much, but it’s worse to pay too little. When you pay too much, you lose a little money — that is all. When you pay too little, you sometimes lose everything, because the thing you bought was incapable of doing…

Lire la suite