modified files to make all tests pass in rspec