Cosmetic changes and resolve rspec deprecation