Monday, June 11, 2012

I'm not sure that's the proper use of a mocking framework

There's no code.  Just unit tests.  So they always pass.

There's a good article at jhovgaard.net called "How I stopped writing awesome code".  At one point he differentiates unit tests versus the UI tests he runs with the statement, "my tests tells me what will make my boss sad, and your test tells you what code that breaks."  It's a compelling argument, although enough UI/integration tests smell a lot like unit tests as long as you're covering all the functionality.  Using Selenium for Firefox is a wise recommendation, particularly with smaller projects where he's right, what the customer sees in the UI is of overriding importance.

Title: I'm not sure that's the proper use of a mocking framework.
Snarky: There's no code.  Just unit tests.  So they always pass.

No comments:

Post a Comment