#NEWLINE# def test_transfer_summary( self ) : #NEWLINE# #INDENT# event = Event . objects . create ( stripe_id = TRANSFER_CREATED_TEST_DATA [ 'id' ] , kind = 'transfer.created' , livemode = True , webhook_message = TRANSFER_CREATED_TEST_DATA , validated_message = TRANSFER_CREATED_TEST_DATA , valid = True ) #NEWLINE# event . process ( ) #NEWLINE# event = Event . objects . create ( stripe_id = TRANSFER_CREATED_TEST_DATA2 [ 'id' ] , kind = 'transfer.created' , livemode = True , webhook_message = TRANSFER_CREATED_TEST_DATA2 , validated_message = TRANSFER_CREATED_TEST_DATA2 , valid = True ) #NEWLINE# event . process ( ) #NEWLINE# self . assertEquals ( Transfer . objects . during ( 2012 , 9 ) . count ( ) , 2 ) #NEWLINE# totals = Transfer . objects . paid_totals_for ( 2012 , 9 ) #NEWLINE# self . assertEquals ( totals [ 'total_amount' ] , decimal . Decimal ( '19.10' ) ) #NEWLINE# self . assertEquals ( totals [ 'total_net' ] , decimal . Decimal ( '19.10' ) ) #NEWLINE# self . assertEquals ( totals [ 'total_charge_fees' ] , decimal . Decimal ( '0.90' ) ) #NEWLINE# self . assertEquals ( totals [ 'total_adjustment_fees' ] , decimal . Decimal ( '0' ) ) #NEWLINE# self . assertEquals ( totals [ 'total_refund_fees' ] , decimal . Decimal ( '0' ) ) #NEWLINE# self . assertEquals ( event [ 'total_validation_fees' ] , decimal . Decimal ( '0' ) )