gueorgui/sanpo — pull request #3 by cwabbott (2012-11-16 12:58:42+00:00)
Title: Specs, improved error handling, and more

I added a few specs mostly for the controllers (next up will be models). Needed factorygirl, so added that to the gemfile.

Updated the exceptions in the controllers to be a little cleaner / easier to deal with. Added a 401.html page.

Modified controllers to before_filter check if the user is signed in. Figure that is a first step toward being able to refactor out some of the validation checks that are happening in controller actions.

Removed the view spec files for now. Just a preference to get rid of them all for the time being.

Be sure you:

```
bundle install
rake db:test:prepare
#then
rake spec
```
And confirm visually that I didn't mess anything up before taking this (I checked out as much as I could -- seemed all ok to me).