3 ms·
> This assumes the code you wrote is already correct and giving the correct answer, so why bother writing tests? It catches regressions. Which is the one thing
by warpspin 8mo ago
> This assumes the code you wrote is already correct and giving the correct answer, so why bother writing tests?
It catches regressions. Which is the one thing where such semi-automated testing is most useful in my eyes.
No clue though why they gave it that weird "expect" name. Basically, it's semi-automated regression testing.
- g8oz 8mo agoExpect is a classic Unix testing utility. So naming it expect gives it a connection to that heritage. https://en.wikipedia.org/wiki/Expect https://en.wikipedia.org/wiki/Expect
- warpspin 8mo agoHmm, yes, I know that one and one of the reasons why I considered the naming weird. Original Tcl expect is rather automation than testing in the slot in my mind it occupies, even if it maybe could be (badly) used as a testing tool.