mirror of
https://github.com/redmine/redmine.git
synced 2025-11-15 17:56:03 +01:00
Fix "ArgumentError: Invalid response name: unprocessable_entity" with Rack 3.1.0+ in assert_response (#39889).
Rack 3.1.0 changed the symbol for HTTP status code 422 from `:unprocessable_entity` to `:unprocessable_content`. Due to the change, `assert_response(:unprocessable_entity, ...)` raises ArgumentError with Rack 3.1.0+. This fix is a follow-up to r22837. git-svn-id: https://svn.redmine.org/redmine/trunk@22876 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -120,7 +120,7 @@ class Redmine::ApiTest::VersionsTest < Redmine::ApiTest::Base
|
||||
:params => {:version => {:name => ''}},
|
||||
:headers => credentials('jsmith'))
|
||||
end
|
||||
assert_response :unprocessable_entity
|
||||
assert_response :unprocessable_content
|
||||
assert_select 'errors error', :text => "Name cannot be blank"
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user