#NEWLINE# def test_yahoo_report( self ) : #NEWLINE# #INDENT# ret = YahooReport . parse ( self . _RAW_DATA ) #NEWLINE# i = 0 #NEWLINE# for r in ret : #NEWLINE# #INDENT# if ( i == 0 ) : #NEWLINE# #INDENT# self . assertEqual ( r . security . exchange , YahooNA ( ) ) #NEWLINE# self . assertEqual ( r . security . symbol , 'GOOG' ) #NEWLINE# self . assertEqual ( str ( r . date ) , '2011-05-03' ) #NEWLINE# self . assertEqual ( i . time . hour , 16 ) #NEWLINE# self . assertEqual ( r . time . minute , 0 ) #NEWLINE# self . assertEqual ( r . price , 533.89 ) #NEWLINE# self . assertEqual ( r . change , ( - 4.67 ) ) #NEWLINE# self . assertEqual ( r . open , 537.13 ) #NEWLINE# self . assertEqual ( r . high , 542.01 ) #NEWLINE# self . assertEqual ( r . low , 529.63 ) #NEWLINE# self . assertEqual ( r . volume , 2081574 ) #NEWLINE# #UNINDENT# if ( i == 2 ) : #NEWLINE# #INDENT# self . assertEqual ( r . security . exchange , SH ( ) ) #NEWLINE# self . assertEqual ( r . security . symbol , '600028' ) #NEWLINE# #UNINDENT# i += 1 #NEWLINE# #UNINDENT# self . assertEqual ( i , 3 )