Skip to content

Instantly share code, notes, and snippets.

@kinopyo
Created March 23, 2012 08:02
Show Gist options
  • Save kinopyo/2168152 to your computer and use it in GitHub Desktop.
Save kinopyo/2168152 to your computer and use it in GitHub Desktop.
Rails Test : Quick hack to get Rack to be quiet about "warning: regexp match /.../n against to UTF-8 string" until we upgrade to Rails 3.1 with Rack 1.3
RSpec.configure do |config|
# ...
end
# quick hack to get Rack to be quiet about "warning: regexp match /.../n against to UTF-8 string" until we upgrade to Rails 3.1 with Rack 1.3
module Rack
module Utils
def escape(s)
CGI.escape(s.to_s)
end
def unescape(s)
CGI.unescape(s)
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment