#NEWLINE# def test_retrieve_view_defn( self ) : #NEWLINE# #INDENT# 'see issue 183' #NEWLINE# view_def = design . ViewDefinition ( 'foo' , 'bar' , 'baz' ) #NEWLINE# result = view_def . sync ( self . db ) #NEWLINE# self . assertTrue ( isinstance ( result , list ) ) #NEWLINE# self . assertEqual ( result [ 0 ] [ 0 ] , True ) #NEWLINE# self . assertEqual ( result [ 0 ] [ 1 ] , '_design/foo' ) #NEWLINE# doc = self . db [ result [ 0 ] [ 1 ] ] #NEWLINE# self . assertEqual ( result [ 0 ] [ 2 ] , view_def [ '_rev' ] )