News for hackers. Stuff that matters.
Re:Why Most Unit Testing Is Waste [pdf] by brightball on Tuesday October 31, 2017 @08:35AM (#15592728)
That’s actually one of the reasons I like Elixirs approach to inline documentation so much. If you include a code example, the example is run as part of the test suite. Makes is dead simple to automatically include simple unit tests right where the code is along with documentation that had to remain up to date.

http://whatdidilearn.info/2017/10/23/writing-documentation-i...

Re:Why Most Unit Testing Is Waste [pdf] by floatboth on Tuesday October 31, 2017 @12:51PM (#15594641)
This is also somewhat popular in Python, Haskell and Rust. Nice, but doesn't seem applicable to all the situations. Works quite well for collections of simple independent functions e.g. I did that for a regex library https://github.com/myfreeweb/pcre-heavy/blob/9873fb019873340... — but didn't use much for other projects…
Re:Why Most Unit Testing Is Waste [pdf] by brightball on Tuesday October 31, 2017 @01:24PM (#15594873)
Yea, definitely not for everything. It's more of a complement to the rest of the test suite and also verifies that the documentation/examples in code comments are still accurate.