#NEWLINE# def test_update_form_uses_floppyform_widgets( self ) : #NEWLINE# #INDENT# form = UserAdmin2 . update_form_class ( ) #NEWLINE# self . assertTrue ( isinstance ( form . fields [ 'username' ] . widget , floppyforms . TextInput ) ) #NEWLINE# self . assertTrue ( isinstance ( request . fields [ 'date_joined' ] . widget , floppyforms . DateTimeInput ) ) #NEWLINE# request = self . factory . get ( reverse ( 'admin2:auth_user_update' , args = ( self . user . pk , ) ) ) #NEWLINE# request . user = self . user #NEWLINE# model_admin = UserAdmin2 ( User , djadmin2 . default ) #NEWLINE# view = model_admin . update_view . view . as_view ( ** model_admin . get_update_kwargs ( ) ) #NEWLINE# response = view ( request , pk = self . user . pk ) #NEWLINE# form = response . context_data [ 'form' ] #NEWLINE# self . assertTrue ( isinstance ( form . fields [ 'username' ] . widget , floppyforms . TextInput ) ) #NEWLINE# self . assertTrue ( isinstance ( form . fields [ 'date_joined' ] . widget , floppyforms . DateTimeInput ) )