Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added failing test to demonstrate digest authentication failure

  • Loading branch information...
commit dc1a83ef5f927157f3eb2871bf3d641c07ff7de8 1 parent 87c57bb
@jcarlson jcarlson authored
Showing with 10 additions and 0 deletions.
  1. +10 −0 actionpack/test/controller/http_digest_authentication_test.rb
View
10 actionpack/test/controller/http_digest_authentication_test.rb
@@ -208,6 +208,16 @@ def authenticate_with_request
assert !ActionController::HttpAuthentication::Digest.validate_digest_response(@request, "SuperSecret"){nil}
end
+ test "authentication request with request-uri ending in '?'" do
+ @request.env['HTTP_AUTHORIZATION'] = encode_credentials(:username => 'pretty', :password => 'please',
+ :uri => '/http_digest_authentication_test/dummy_digest?')
+ @request.env['PATH_INFO'] = "/http_digest_authentication_test/dummy_digest?"
+ get :display
+
+ assert_response :success
+ assert_equal 'Definitely Maybe', @response.body
+ end
+
private
def encode_credentials(options)
Please sign in to comment.
Something went wrong with that request. Please try again.