Remove the deprecated config.whiny_nils in dev and test
Use the new Rails 4.0 syntax for scopes
The use of stub (in some cases?) is deprecated - use double instead