#NEWLINE# def test_from_portable_primitive( self ) : #NEWLINE# #INDENT# obj = SimpleSchema ( _primitive_data = { #NEWLINE# #INDENT# 'charfield' : 'charmander' , #NEWLINE# #UNINDENT# } ) #NEWLINE# assert obj . charfield , 'Failed to initialize python data' #NEWLINE# py_obj = obj . to_python ( { #NEWLINE# #INDENT# 'charfield' : 'charmander' , #NEWLINE# #UNINDENT# } ) #NEWLINE# py_obj . normalize_portable_primitives ( ) #NEWLINE# self . assertEqual ( obj . _primitive_data , py_obj . _primitive_data )