Hacker News new | past | comments | ask | show | jobs | submit login

"Unit testing isn't a big part of QuickBooks for Windows — the bulk of the codebase was written before unit testing was acknowledged as a best practice."

If there was ever an application that would benefit greatly from unit testing, this is it.




I'm a developer on QuickBooks for Windows.

Code bases where fundamental aspects (models, database interaction, custom UI libraries, etc.) were developed and solidified far before unit testing was the norm or expected are a tough nut to crack, but we are making improvements every day. Within the last three months I've solved compilation and linker hurdles and we're now integrated with googletest and googlemock, which are fantastic libraries!

Also, while our list of C++ unit tests is small but growing now, the use of NUnit, etc. was championed from Day One on C# projects stretching back to our usage of .Net 1.1.

It's interesting how much working with Ruby the last 7 years has affected my C++ development. I'm dual-wielding Avid Grimm's Objects-on-Rails and Michael Feather's Working Effectively with Legacy Code with great results.


Well done - you are obviously doing a good job with a huge codebase.


I would agree with what you said if you replaced "an application" with "a kind of application". This is a 10MLoC project that was mostly not written for unit testablility. As stated in the article, they are doing automatic integration testing on a functional level to catch regressions. They are enforcing zero warnings and run static analysis software. And most importantly, their code has worked in the field for a long time. I strongly suspect that refactoring for unit testability would be a very significant risk in their case. The quote does not say that they don't unit-test new code.


Agreed - I didn't mean for it to be criticism of the project, but that line just jumped out at me. Like you say, for new projects they are using unit testing.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: