@@ -304,7 +304,7 @@ def setup
304304 # server error or is otherwise undecipherable.
305305 def test_bad_response
306306 assert_log_matches ( 'Server error when requesting an association' ) {
307- assert_equal ( call_negotiate ( [ mk_message ( { } ) ] ) , nil )
307+ assert_nil ( call_negotiate ( [ mk_message ( { } ) ] ) )
308308 }
309309 end
310310
@@ -320,7 +320,7 @@ def test_empty_assoc_type
320320 "Server #{ @server_url } responded with unsupported " \
321321 "association session but did not supply a fallback."
322322 ) {
323- assert_equal ( call_negotiate ( [ msg ] ) , nil )
323+ assert_nil ( call_negotiate ( [ msg ] ) )
324324 }
325325
326326 end
@@ -337,7 +337,7 @@ def test_empty_session_type
337337 "Server #{ @server_url } responded with unsupported " \
338338 "association session but did not supply a fallback."
339339 ) {
340- assert_equal ( call_negotiate ( [ msg ] ) , nil )
340+ assert_nil ( call_negotiate ( [ msg ] ) )
341341 }
342342 end
343343
@@ -357,7 +357,7 @@ def test_not_allowed
357357
358358 assert_log_matches ( 'Unsupported association type' ,
359359 'Server sent unsupported session/association type:' ) {
360- assert_equal ( call_negotiate ( [ msg ] , negotiator ) , nil )
360+ assert_nil ( call_negotiate ( [ msg ] , negotiator ) )
361361 }
362362 end
363363
@@ -388,7 +388,7 @@ def test_unsupported_with_retry_and_fail
388388
389389 assert_log_matches ( 'Unsupported association type' ,
390390 "Server #{ @server_url } refused" ) {
391- assert_equal ( call_negotiate ( [ msg , msg ] ) , nil )
391+ assert_nil ( call_negotiate ( [ msg , msg ] ) )
392392 }
393393 end
394394
@@ -424,7 +424,7 @@ def setup
424424 def test_bad_response
425425 assert_log_matches ( 'Server error when requesting an association' ) {
426426 response = call_negotiate ( [ mk_message ( { } ) ] )
427- assert_equal ( nil , response )
427+ assert_nil ( response )
428428 }
429429 end
430430
@@ -436,7 +436,7 @@ def test_empty_assoc_type
436436
437437 assert_log_matches ( 'Server error when requesting an association' ) {
438438 response = call_negotiate ( [ msg ] )
439- assert_equal ( nil , response )
439+ assert_nil ( response )
440440 }
441441 end
442442
@@ -448,7 +448,7 @@ def test_empty_session_type
448448
449449 assert_log_matches ( 'Server error when requesting an association' ) {
450450 response = call_negotiate ( [ msg ] )
451- assert_equal ( nil , response )
451+ assert_nil ( response )
452452 }
453453 end
454454
@@ -466,7 +466,7 @@ def test_not_allowed
466466
467467 assert_log_matches ( 'Server error when requesting an association' ) {
468468 response = call_negotiate ( [ msg ] )
469- assert_equal ( nil , response )
469+ assert_nil ( response )
470470 }
471471 end
472472
@@ -482,7 +482,7 @@ def test_unsupported_with_retry
482482
483483 assert_log_matches ( 'Server error when requesting an association' ) {
484484 response = call_negotiate ( [ msg , assoc ] )
485- assert_equal ( nil , response )
485+ assert_nil ( response )
486486 }
487487 end
488488
@@ -818,13 +818,13 @@ def set_negotiate_response(assoc)
818818
819819 def test_not_in_store_no_response
820820 set_negotiate_response ( nil )
821- assert_equal ( nil , @assoc_manager . get_association )
821+ assert_nil ( @assoc_manager . get_association )
822822 end
823823
824824 def test_not_in_store_negotiate_assoc
825825 # Not stored beforehand:
826826 stored_assoc = @store . get_association ( @server_url , @assoc . handle )
827- assert_equal ( nil , stored_assoc )
827+ assert_nil ( stored_assoc )
828828
829829 # Returned from associate call:
830830 set_negotiate_response ( @assoc )
@@ -898,7 +898,7 @@ def test_success
898898 def test_missing_fields
899899 @message . del_arg ( OPENID_NS , 'assoc_type' )
900900 assert_log_matches ( 'Missing required par' ) {
901- assert_equal ( nil , make_request )
901+ assert_nil ( make_request )
902902 }
903903 end
904904
@@ -907,7 +907,7 @@ def test_missing_fields
907907 def test_protocol_error
908908 @message . set_arg ( OPENID_NS , 'expires_in' , 'goats' )
909909 assert_log_matches ( 'Protocol error processing' ) {
910- assert_equal ( nil , make_request )
910+ assert_nil ( make_request )
911911 }
912912 end
913913 end
0 commit comments