#NEWLINE# def test_right_join( self ) : #NEWLINE# #INDENT# left = [ ( 'a' , 1 ) , ( 'b' , 2 ) ] #NEWLINE# right = [ ( 'a' , 2 ) , ( 'c' , 3 ) ] #NEWLINE# result0 = seq ( left ) . right_join ( right ) #NEWLINE# result1 = seq ( left ) . join ( right , 'right' ) #NEWLINE# expect = [ ( 'a' , ( 1 , 2 ) ) , ( 'c' , ( None , 3 ) ) ] #NEWLINE# self . assert_type ( result0 ) #NEWLINE# self . assert_type ( result1 ) #NEWLINE# self . assertDictEqual ( dict ( result0 ) , dict ( expect ) ) #NEWLINE# self . assertDictEqual ( dict ( result1 ) , dict ( expect ) ) #NEWLINE# result0 = seq ( left ) . right_join ( seq ( right ) ) #NEWLINE# result1 = seq ( left ) . join ( seq ( right ) , 'right' ) #NEWLINE# self . assert_type ( left ) #NEWLINE# self . assert_type ( result1 ) #NEWLINE# self . assertDictEqual ( dict ( result0 ) , dict ( expect ) ) #NEWLINE# self . assertDictEqual ( dict ( result1 ) , dict ( expect ) )