#NEWLINE# def test_GET( self ) : #NEWLINE# #INDENT# p = DBPerson ( name = u ( 'Pierre-Joseph' ) , birthdate = datetime . date ( 1809 , 1 , 15 ) ) #NEWLINE# DBSession . add ( p ) #NEWLINE# DBSession . flush ( ) #NEWLINE# pid = p . id #NEWLINE# r = self . app . get ( ( '/person?ref.id=%s' % pid ) , headers = { #NEWLINE# #INDENT# 'Accept' : 'application/json' , #NEWLINE# #UNINDENT# } ) #NEWLINE# r = json . loads ( r . text ) #NEWLINE# print ( r ) #NEWLINE# assert ( r [ 'name' ] == u ( 'Pierre-Joseph' ) ) #NEWLINE# assert ( r [ 'birthdate' ] == u ( '1809-01-15' ) )