3 ms·
> How do you fix the things that the test prove are broken? Uhm. The tests don’t do any such things. > It is better to spend the time figuring out what all th
by krisoft 4y ago
> How do you fix the things that the test prove are broken?
Uhm. The tests don’t do any such things.
> It is better to spend the time figuring out what all the features are, document them
Yes. And the tests you should write are executable documentation showing how things are. It is like taking a plaster cast of a fossil. You don’t go “i think this is how a brachiosaurus fibula should look like” and then try to force the bones into that shape. You mould the plaster cast (your tests) to the shape of the fossil (the code running in production). Then if during excavation (the rewrite) something changes or get jostled you will know immediately that it happened, because the cast (the tests) no longer fit.