Add #to_s method to rails version

Rails.version returns an instance of Gem::Version
ref rails/rails#8501, https://travis-ci.org/rails/rails/jobs/5750326