#NEWLINE# def test_modelformset_factory_default( self ) : #NEWLINE# #INDENT# Formset = modelformset_factory ( UserSite , form = UserSiteForm ) #NEWLINE# form = Formset ( ) . forms [ 0 ] #NEWLINE# self . assertTrue ( isinstance ( form [ 'data' ] . field . widget , CustomWidget ) )