Skip to content

Commit

Permalink
Fix test failures from changing the symbols to strings in 1b8c520
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason L Perry committed Sep 12, 2009
1 parent 0deb6bb commit 0e4dd60
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/verify_recaptcha_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ def setup
@controller.params = {:recaptcha_challenge_field => "challenge", :recaptcha_response_field => "response"}

@expected_post_data = {}
@expected_post_data[:privatekey] = ENV['RECAPTCHA_PRIVATE_KEY']
@expected_post_data[:remoteip] = @controller.request.remote_ip
@expected_post_data[:challenge] = "challenge"
@expected_post_data[:response] = "response"
@expected_post_data["privatekey"] = ENV['RECAPTCHA_PRIVATE_KEY']
@expected_post_data["remoteip"] = @controller.request.remote_ip
@expected_post_data["challenge"] = "challenge"
@expected_post_data["response"] = "response"

@expected_uri = URI.parse("http://#{Ambethia::ReCaptcha::RECAPTCHA_VERIFY_SERVER}/verify")
end
Expand Down Expand Up @@ -62,7 +62,7 @@ def test_errors_should_be_added_to_model
def test_returns_true_on_success_with_optional_key
@controller.session[:recaptcha_error] = "previous error that should be cleared"
# reset private key
@expected_post_data[:privatekey] = 'ADIFFERENTPRIVATEKEYXXXXXXXXXXXXXX'
@expected_post_data["privatekey"] = 'ADIFFERENTPRIVATEKEYXXXXXXXXXXXXXX'
expect_http_post(response_with_body("true\n"))

assert @controller.verify_recaptcha(:private_key => 'ADIFFERENTPRIVATEKEYXXXXXXXXXXXXXX')
Expand Down

0 comments on commit 0e4dd60

Please sign in to comment.