#NEWLINE# def test_custom_form_base( ) : #NEWLINE# #INDENT# ( app , db , admin ) = setup ( ) #NEWLINE# class TestForm ( form . BaseForm ) : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# ( Model1 , _ ) = create_models ( db ) #NEWLINE# view = CustomModelView ( Model1 , db . session , form_base_class = TestForm ) #NEWLINE# admin . add_view ( view ) #NEWLINE# ok_ ( hasattr ( view . _create_form_class , 'test1' ) ) #NEWLINE# create_form = view . create_form ( ) #NEWLINE# ok_ ( isinstance ( create_form , TestForm ) )