try-catch-FAIL

Failure is inevitable

NAVIGATION - SEARCH

Encapsulating Query Logic in MVC Apps Without the Repository Pattern

One of the most common questions I get when people see a video or presentation about how I build MVC applications is, “Why don’t you use the repository pattern?”  There are a lot of reasons not to use the repository pattern, and they’ve been well-covered by others.  But, one valid benefit they provide is encapsulation of query logic.  In this post, I’ll show you how you can maintain encapsulation in your applications without having to use the repository pattern. More...

Introducing SpecsFor<Web> Helpers!

SpecsFor<Web> Helpers will help you write cleaner, easier-to-read (and maintain!) specs for your ASP.NET MVC applications.  It’s the latest addition to the SpecsFor family, and the first of the Helpers line that I’m working on.  Read on to see what it can do for you and your team! More...

A Better Way to Configure AutoMapper for ASP.NET MVC (Video)

AutoMapper is one of the essential tools in my ASP.NET MVC toolbelt.  I use it on every MVC project I do.  It's saved me countless lines of code over the years.  And yet, there's always been one thing that bugged me about it: it violates the idea of "common closure."  I've built a better way to handle this, but as my friends have accused reminded me, I might have forgotten to share this approach publicly.  Until now. More...

SpecsFor.Mvc 3.0.0 Final Released

I just published the final version of SpecsFor.Mvc 3.0.0.  As I mentioned previously, this update adds support for MVC 5.0, drops the dependency on MVCContrib and Rhino Mocks, and includes a handful of other fixes.  Next on the SpecsFor.Mvc agenda is improving the initial setup experience and eliminating pain around lingering IIS Express and Selenium processes.  In the meantime, please let me know if you run into any problems with SpecsFor.Mvc via the Github project page.

Come See Me at CodeStock 2013!

I’m very pleased to announce that I’ll be presenting at CodeStock again this year.  I think this makes 4 years straight (though that seems impossible, I can’t be that old!)  Here’s what I’ll be talking about in Knoxville this year: More...

A View Engine for ASP.NET MVC Feature-Based Organized

I am a huge fan of ASP.NET MVC.  It is leaps and bounds ahead of WebForms, and if you’re doing web development on the Microsoft platform, it’s arguably the best overall solution available.  But it is far from perfect.  One of the things that has bugged me about it since the very beginning is the default organization conventions, meaning separate folders for controllers, view models, and views.  These conventions can be replaced though.  Read on to see how. More...

SpecsFor.Mvc 2.0 Released

SpecsFor.Mvc 2.0 is out today.  This release includes drastically improved performance, support for Chrome, and support for the very latest versions of Selenium, ASP.NET MVC, and other libraries. More...