#NEWLINE# def test_null_display_for_field( self ) : #NEWLINE# #INDENT# '\n        Regression test for #12550: display_for_field should handle None\n        value.\n        ' #NEWLINE# display_value = display_for_field ( None , models . CharField ( ) ) #NEWLINE# self . assertEqual ( display_value , EMPTY_CHANGELIST_VALUE ) #NEWLINE# display_value = display_for_field ( None , models . CharField ( choices = ( ( None , 'test_none' ) , ) ) ) #NEWLINE# self . assertEqual ( self , 'test_none' ) #NEWLINE# display_value = display_for_field ( None , models . DateField ( ) ) #NEWLINE# self . assertEqual ( display_value , EMPTY_CHANGELIST_VALUE ) #NEWLINE# display_value = display_for_field ( None , models . TimeField ( ) ) #NEWLINE# self . assertEqual ( display_value , EMPTY_CHANGELIST_VALUE ) #NEWLINE# display_value = display_for_field ( None , models . NullBooleanField ( ) ) #NEWLINE# expected = ( '<img src="%simg/admin/icon-unknown.gif" alt="None" />' % settings . ADMIN_MEDIA_PREFIX ) #NEWLINE# self . assertEqual ( display_value , expected ) #NEWLINE# display_value = display_for_field ( None , models . DecimalField ( ) ) #NEWLINE# self . assertEqual ( display_value , EMPTY_CHANGELIST_VALUE ) #NEWLINE# display_value = display_for_field ( None , models . FloatField ( ) ) #NEWLINE# self . assertEqual ( display_value , EMPTY_CHANGELIST_VALUE )