File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ def get_transaction_type(
3939 txn_type = TransactionType .STT_TAX
4040 elif "stamp" in description :
4141 txn_type = TransactionType .STAMP_DUTY_TAX
42- elif ( "segregate " in description . lower ()) or ( "segregation" in description . lower ()) :
42+ elif "segregat " in description :
4343 txn_type = TransactionType .SEGREGATION
4444 else :
4545 txn_type = TransactionType .MISC
Original file line number Diff line number Diff line change @@ -41,7 +41,9 @@ def test_transaction_type(self):
4141 None ,
4242 )
4343 assert get_transaction_type ("Address updated" , None ) == (TransactionType .MISC , None )
44- assert get_transaction_type ("***STT paid ***" , None ) == (TransactionType .TAX , None )
44+ assert get_transaction_type ("***STT paid ***" , None ) == (TransactionType .STT_TAX , None )
45+ assert get_transaction_type ("***stamp duty***" , None ) == (TransactionType .STAMP_DUTY_TAX , None )
46+ assert get_transaction_type ("Creation of units - Segregated portfolio" , None ) == (TransactionType .SEGREGATION , None )
4547 assert get_transaction_type ("***Random text***" , Decimal (0.0 )) == (
4648 TransactionType .UNKNOWN ,
4749 None ,
You can’t perform that action at this time.
0 commit comments