News for hackers. Stuff that matters.
Re:Clojure 1.6 released by bad_user on Tuesday March 25, 2014 @02:38PM (#7467853)
TDD is meant for supposedly helping with design. It does help, well sort of - it helps in writing code that is more testable. That's a plus, since the more you wait to introduce testing in your project, the harder it gets to do so. But you can't rely on it for the actual problem solving. Here's the proof: http://devgrind.com/2007/04/25/how-to-not-solve-a-sudoku/

I've watched Rich Hickey's talks and he makes fun of TDD as a design tool. And that's it. This doesn't negate the value of automated testing in general. Testing helps to ensure that the primary use-cases of your software system are fulfilled and to guard against regressions. When you get a bug, you write a test for it. When you forget about a business rule and find out you broke it later, you write a test for it. When you refactor code, it's very useful to have a suite of tests that ensure at least the main business logic still works.

TDD on the other hand is something different. Writing the test case first, before writing the code that passes it, always seemed like a dumb idea to me. So I always write my tests after and I'm not crazy about good code coverage either. But you do need tests for non-toy projects.

Re:Clojure 1.6 released by rikf on Wednesday March 26, 2014 @02:47AM (#7471981)
If your writing tests after the unit then you not doing TDD right.

TDD is not designed to be a good technique for developing algorithm's but rather for designing OO systems and discovering the collaborations between various objects within a system. This doesn't mean you can forget about solid OO design principals and just somehow land up with a good design just because you use TDD.

Re:Clojure 1.6 released by dusklight on Tuesday March 25, 2014 @04:39PM (#7468793)
why are you not crazy about good code coverage?
Re:Clojure 1.6 released by pbowyer on Tuesday March 25, 2014 @06:20PM (#7469621)
Ian Cooper says it better than I can: http://vimeo.com/68375232

If you've not seen that before, it's seriously good. My top video of 2013

Re:Clojure 1.6 released by tieTYT on Tuesday March 25, 2014 @10:30PM (#7471178)
Wow that was amazing. What are your other top videos?