Finally add specs

Time to add some automated tests in preparation for upgrade to Rails 4.2.