add auth store test
parent
d54a93a64a
commit
c3e8c15c6b
|
@ -0,0 +1,13 @@
|
|||
require "./spec_helper"
|
||||
|
||||
describe "Mechanize AuthStore test" do
|
||||
it "add_auth" do
|
||||
auth_store = Mechanize::HTTP::AuthStore.new
|
||||
url = URI.parse("http://example.com/")
|
||||
user = "kanezoh"
|
||||
password = "password"
|
||||
auth_store.add_auth(url, user, password)
|
||||
auth_store.auth_accounts.size.should eq 1
|
||||
auth_store.auth_accounts[url].should eq({"kanezoh", "password"})
|
||||
end
|
||||
end
|
Loading…
Reference in New Issue