diff options
author | Azul <azul@riseup.net> | 2012-10-04 10:47:19 +0200 |
---|---|---|
committer | Azul <azul@riseup.net> | 2012-10-04 10:47:19 +0200 |
commit | 66c3ed01eb012cae84193b4864c7c48eb77c2a8c (patch) | |
tree | b23d69a19f60cc46a1baa4328cb34c703bea4bbf /test/auth_test.rb | |
parent | c73f7c1b4c1270d4d0ca47650a12893a6d13e796 (diff) |
more cleanup - no more duplicate password and username in Client
A client has a set of pwd and login and tries to auth with this.
Diffstat (limited to 'test/auth_test.rb')
-rw-r--r-- | test/auth_test.rb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/test/auth_test.rb b/test/auth_test.rb index 559403a..c1bffd0 100644 --- a/test/auth_test.rb +++ b/test/auth_test.rb @@ -32,15 +32,17 @@ class AuthTest < Test::Unit::TestCase end def test_successful_auth - assert @client.authenticate(@server, @username, @password) + assert @client.authenticate(@server) end def test_a_wrong_password - assert !@client.authenticate(@server, @username, "wrong password") + client = SRP::Client.new(@username, "wrong password", @client.salt) + assert !client.authenticate(@server) end def test_wrong_username - assert !@client.authenticate(@server, "wrong username", @password) + client = SRP::Client.new("wrong username", @password, @client.salt) + assert !client.authenticate(@server) end end |