3 ms·
That, and correct code is often not very testable, at first. My process is write code -> repeat until it works -> refactor code until the tests make sense -> b
by klodolph 10y ago
That, and correct code is often not very testable, at first.
My process is write code -> repeat until it works -> refactor code until the tests make sense -> break up code into individual tested commits -> submit for review.
After enough years of this you end up with a grab bag of techniques both for writing testable code and for writing tests.