refactored code in both bike.rb and bike_spec.rb