4 ms·
I am confused about the example with the 'Greeting' function breaking the test. Did the author see this as an issue with testing? If the functionality is chang
by loxdalen 3y ago
I am confused about the example with the 'Greeting' function breaking the test. Did the author see this as an issue with testing?
If the functionality is changed, the tests will have to be changed to reflect that. One feature of tests is that they are are documentation for the expected functionality of code, so naturally it needs to be updated when functionality changes. It is a feature in my opinion.
- brundolf 3y agoYeah, the idea isn't that this type of code should never be tested but that it's a higher burden to test, and maybe less valuable to test, compared with other code. And that should be factored into the decision (and there should be a decision) on whether or not to test it