Skip to content

Commit

Permalink
Added a test for cnonce uniqueness
Browse files Browse the repository at this point in the history
  • Loading branch information
drbrain committed May 19, 2012
1 parent 62385e6 commit 87d6c7f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/test_net_http_digest_auth.rb
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ def test_auth_header_unknown_algorithm
end

def test_make_cnonce
assert_match %r%\A[a-f\d]{32}\z%, @da.make_cnonce
cnonce = @da.make_cnonce
assert_match %r%\A[a-f\d]{32}\z%, cnonce
refute_equal cnonce, @da.make_cnonce
end

def test_next_nonce
Expand Down

0 comments on commit 87d6c7f

Please sign in to comment.