finished program based on rspec