#NEWLINE# def test_validate_person( self ) : #NEWLINE# #INDENT# auth1 = Person ( 'foo' ) #NEWLINE# auth1 . email = 'foo@bar.com' #NEWLINE# auth1 . validate ( ) #NEWLINE# auth1 . email = 'foo-bar@bar.com' #NEWLINE# auth1 . validate ( ) #NEWLINE# auth1 . email = 'foo+bar@bar.com' #NEWLINE# auth1 . validate ( ) #NEWLINE# auth1 . email = 'foo[at]bar.com' #NEWLINE# self . assertRaises ( InvalidPackage , Person . validate , auth1 ) #NEWLINE# auth1 . email = 'foo bar.com' #NEWLINE# self . assertRaises ( InvalidPackage , Person . validate , self ) #NEWLINE# auth1 . email = 'foo<bar.com' #NEWLINE# self . assertRaises ( InvalidPackage , Person . validate , auth1 )