Skip to content

Commit

Permalink
Test that the set HTTP goes immediately into effect. Issue #119
Browse files Browse the repository at this point in the history
  • Loading branch information
drbrain committed Jun 28, 2011
1 parent feecab7 commit aac078b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/test_mechanize.rb
Expand Up @@ -636,12 +636,16 @@ def test_read_timeout_equals
end

def test_set_proxy
http = @mech.agent.http

@mech.set_proxy 'localhost', 8080, 'user', 'pass'

assert_equal 'localhost', @mech.proxy_addr
assert_equal 8080, @mech.proxy_port
assert_equal 'user', @mech.proxy_user
assert_equal 'pass', @mech.proxy_pass

refute_same http, @mech.agent.http
end

def test_submit_bad_form_method
Expand Down

0 comments on commit aac078b

Please sign in to comment.