1
0
fin-depo/test/test_partisia_blockchain.py

24 lines
705 B
Python
Raw Normal View History

2024-07-18 22:53:14 +00:00
import fin_defs
import requests
from fin_depo import defi_partisia_blockchain
def test_get_depo():
session = requests.Session()
fetcher = defi_partisia_blockchain.PartisiaBlockchainAccountDepoFetcher(
session,
'00f3a778fbcf663e4f0d47b41aa4ec51e0f9d39d60',
)
depo = fetcher.get_depo()
assert depo is not None
assert depo.name == 'Partisia Blockchain'
assert depo.updated_time is not None
assert depo.nested[0].name == 'Native'
assert depo.nested[0].updated_time == depo.updated_time
assert depo.nested[1].name == 'Bring Your Own Coin'
assert depo.nested[1].updated_time == depo.updated_time
assert depo.get_amount_of_asset(fin_defs.MPC)