Fixing warning from rspec
Including changes from #103 with tests