#NEWLINE# def test_INPhoneNumberField( self ) : #NEWLINE# #INDENT# error_format = [ 'Phone numbers must be in 02X-8X or 03X-7X or 04X-6X format.' ] #NEWLINE# valid = { #NEWLINE# #INDENT# '0423-2443667' : '0423-2443667' , #NEWLINE# '0423 2443667' : '0423 2443667' , #NEWLINE# '04236-244366' : '04236-244366' , #NEWLINE# '040-24436678' : '040-24436678' , #NEWLINE# #UNINDENT# } #NEWLINE# invalid = { #NEWLINE# #INDENT# '04-2443667' : error_format , #NEWLINE# '423-2443667' : error_format , #NEWLINE# '0423-9442667' : error_format , #NEWLINE# '0423-0443667' : error_format , #NEWLINE# '0423-244366' : error_format , #NEWLINE# '04232442667' : error_format , #NEWLINE# '0423DJANGO' : error_format , #NEWLINE# #UNINDENT# } #NEWLINE# self . assertFieldOutput ( INPhoneNumberField , valid , invalid )