#NEWLINE# def test_field_types( self ) : #NEWLINE# #INDENT# ReferencingModelForm = modelform_factory ( ReferencingModel , exclude = ( 'id' , ) ) #NEWLINE# form = ReferencingModelForm ( ) #NEWLINE# self . assertTrue ( isinstance ( form . fields [ 'fk' ] , TreeNodeChoiceField ) ) #NEWLINE# self . assertTrue ( isinstance ( form . fields [ 'one' ] , TreeNodeChoiceField ) ) #NEWLINE# self . assertTrue ( isinstance ( form . fields [ 'm2m' ] , TreeNodeMultipleChoiceField ) )