3 ms·
You will write tests, because without them, you cannot refactor. With them, you will be able to quickly and easily make your code better and better, with much
by kgilpin 10y ago
You will write tests, because without them, you cannot refactor.
With them, you will be able to quickly and easily make your code better and better, with much less risk of regression.
As a result, the initial implementation details of your code are not very important, and you don't have to spend much time thinking about how the code might evolve in the future (which is unknowable anyway).
PS Don't spent much time testing the internals of your code. Check that the inputs and outputs are correct, as thoroughly as you can. Testing internals actually makes refactoring harder.