#NEWLINE# def test_encode_data( self ) : #NEWLINE# #INDENT# data = { #NEWLINE# #INDENT# 'key' : 'value' , #NEWLINE# #UNINDENT# } #NEWLINE# utf8_data = json . dumps ( data ) . encode ( 'utf-8' ) #NEWLINE# encoded_data = b64encode ( utf8_data ) . decode ( 'utf-8' ) #NEWLINE# self . assertEqual ( self . json_manager . _encode_data ( data ) , encoded_data )