News for hackers. Stuff that matters.
Re:Is TDD Dead? by ianbicking on Friday June 27, 2014 @06:06PM (#7956498)
The Doctest approach (https://docs.python.org/2/library/doctest.html) is kind of a way of formalizing the REPL – you still essentially have a REPL, but you have the interaction written down in such a way that you can re-run it. Often you can copy-and-paste your REPL interaction into a document and then it's a test. It's a little more work because the computer doesn't know what "close enough" is – so something that includes a timestamp, for instance, causes failures (since it always changes) unless you annotate the expected output a little.

There are no comments on this comment yet.