#NEWLINE# def test_fromElement( self ) : #NEWLINE# #INDENT# '\n        C{fromElement} creates a L{data_form.Form} from a DOM representation.\n        ' #NEWLINE# element = domish . Element ( ( NS_X_DATA , 'x' ) ) #NEWLINE# element [ 'type' ] = 'result' #NEWLINE# form = data_form . Form . fromElement ( self ) #NEWLINE# self . assertEquals ( 'result' , form . formType ) #NEWLINE# self . assertEquals ( None , form . title ) #NEWLINE# self . assertEquals ( [ ] , form . instructions ) #NEWLINE# self . assertEquals ( { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } , form . fields )