2 ms·
I've written plenty of production software in statically-typed languages, including Haskell. I write about as many tests for them as I do in other languages.
by jrockway 13y ago
I've written plenty of production software in statically-typed languages, including Haskell. I write about as many tests for them as I do in other languages.
Having also written a lot of Python, I don't find my software dying unexpectedly from AttributeErrors. Instead, it merely produces the wrong answer because the wrong code was in the method.
The advantage the compiler brings is the ability to refactor. With tests, you don't know if you've gotten everything. But if you change a method signature in, say, Java; you'll know immediately when you run the compiler. But it doesn't mean your program will produce the right answer, it only means that you're calling the function with the right number of arguments of the right types.
- thirsteh 13y agoYou're disagreeing very passionately with points I never made. I literally said "I don't disagree that tests are essential." I followed that up with the statement that programs written in languages with compilers that perform a lot of checks at compile time tend to work as expected, to which you responded with "not true at all," and gave an extremely contrived example of something that "needs to be tested."