#NEWLINE# def testParseUndefined( self ) : #NEWLINE# #INDENT# str = ( ( '2011/02/05 * Bookshop\n' + '    Assets:Bank\n' ) + '    Expenses:Book' ) #NEWLINE# with self . assertRaises ( UndefinedTransaction ) as cm : #NEWLINE# #INDENT# self . parser . parse_transaction ( str )