on_transaction -> ledger.wait
This commit is contained in:
parent
5658623f29
commit
b2117fddab
2 changed files with 7 additions and 7 deletions
|
@ -608,7 +608,7 @@ class PublishCommand(CommandTestCase):
|
||||||
|
|
||||||
class AbandonCommand(CommandTestCase):
|
class AbandonCommand(CommandTestCase):
|
||||||
|
|
||||||
VERBOSITY = logging.INFO
|
VERBOSITY = logging.WARN
|
||||||
|
|
||||||
async def test_abandoning_claim_at_loss(self):
|
async def test_abandoning_claim_at_loss(self):
|
||||||
|
|
||||||
|
|
|
@ -66,13 +66,13 @@ class BasicTransactionTest(IntegrationTestCase):
|
||||||
await self.broadcast(cert_tx)
|
await self.broadcast(cert_tx)
|
||||||
await self.broadcast(claim_tx)
|
await self.broadcast(claim_tx)
|
||||||
await asyncio.wait([ # mempool
|
await asyncio.wait([ # mempool
|
||||||
self.on_transaction(claim_tx),
|
self.ledger.wait(claim_tx),
|
||||||
self.on_transaction(cert_tx)
|
self.ledger.wait(cert_tx)
|
||||||
])
|
])
|
||||||
await self.blockchain.generate(1)
|
await self.blockchain.generate(1)
|
||||||
await asyncio.wait([ # confirmed
|
await asyncio.wait([ # confirmed
|
||||||
self.on_transaction(claim_tx),
|
self.ledger.wait(claim_tx),
|
||||||
self.on_transaction(cert_tx)
|
self.ledger.wait(cert_tx)
|
||||||
])
|
])
|
||||||
|
|
||||||
self.assertEqual(d2l(await self.account.get_balance()), '7.985786')
|
self.assertEqual(d2l(await self.account.get_balance()), '7.985786')
|
||||||
|
@ -84,9 +84,9 @@ class BasicTransactionTest(IntegrationTestCase):
|
||||||
|
|
||||||
abandon_tx = await Transaction.abandon([claim_tx.outputs[0]], [self.account], self.account)
|
abandon_tx = await Transaction.abandon([claim_tx.outputs[0]], [self.account], self.account)
|
||||||
await self.broadcast(abandon_tx)
|
await self.broadcast(abandon_tx)
|
||||||
await self.on_transaction(abandon_tx)
|
await self.ledger.wait(abandon_tx)
|
||||||
await self.blockchain.generate(1)
|
await self.blockchain.generate(1)
|
||||||
await self.on_transaction(abandon_tx)
|
await self.ledger.wait(abandon_tx)
|
||||||
|
|
||||||
response = await self.ledger.resolve(0, 10, 'lbry://@bar/foo')
|
response = await self.ledger.resolve(0, 10, 'lbry://@bar/foo')
|
||||||
self.assertNotIn('claim', response['lbry://@bar/foo'])
|
self.assertNotIn('claim', response['lbry://@bar/foo'])
|
||||||
|
|
Loading…
Reference in a new issue