Created
March 22, 2017 14:21
-
-
Save domcleal/39f0b159faf3eaadacdf1612ac6aea7a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
begin | |
require "bundler/inline" | |
rescue LoadError => e | |
$stderr.puts "Bundler version 1.10 or later is required. Please update your Bundler" | |
raise e | |
end | |
gemfile(true) do | |
source "https://rubygems.org" | |
gem "rails", github: "rails/rails" | |
gem "arel", github: "rails/arel" | |
end | |
require "action_dispatch" | |
require "action_dispatch/http/parameters" | |
require "minitest/autorun" | |
require "rack/test" | |
class BugTest < Minitest::Test | |
def test_catches_parseerror | |
begin | |
raise ActionDispatch::ParamsParser::ParseError | |
rescue ActionDispatch::ParamsParser::ParseError | |
assert true, "caught ParseError" | |
end | |
assert false, "should have raised ParseError" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment