News for hackers. Stuff that matters.
Re:Writing unit tests is reinventing functional programming ... by lacker on Wednesday February 25, 2009 @11:15AM (#494508)
I think you have overdosed on acronyms.
Re:Writing unit tests is reinventing functional programming ... by darkxanthos on Wednesday February 25, 2009 @06:00PM (#495088)
So... I am an avid Test Driven Development/Unit Test/Behavior Driven Development guy. I've been gravitating towards Behavior Driven Development lately and honestly I don't Dependency Inject everything. Really if I'm just Behavior Driven Develop-ing a layer I just need to inject the fringe dependencies, the things that would cause me to be dependent on other whole systems or sub-systems (think File Input/Output, Active Directory, Web Services, etcetera). My object still contains a lot of state.

I think saying that unit tests cause us to reinvent functional programming is a bit of a stretch. I do think that saying that unit testing causes us to write better code and we borrow heavily from many programming paradigms (Design By Contract, Functional Programming, Object Oriented Programming, Domain Specific Languages, etcetera) in order to write that better code.

:)