Skip to content

Commit

Permalink
Please add comments (Chia-Network#5565)
Browse files Browse the repository at this point in the history
* Please add comments

* Fix issue

* More blocks

Co-authored-by: Adam Kelly <[email protected]>
Co-authored-by: Mariano <[email protected]>
  • Loading branch information
3 people authored May 20, 2021
1 parent ac59ec5 commit 15d4938
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions tests/wallet/test_wallet.py
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,6 @@ async def test_wallet_tx_reorg(self, two_wallet_nodes):
await server_3.start_client(PeerInfo(self_hostname, uint16(fn_server._port)), None)
for i in range(0, num_blocks):
await full_node_api.farm_new_transaction_block(FarmNewBlockProtocol(ph))
await time_out_assert(10, wallet_node.wallet_state_manager.blockchain.get_peak_height, 5)

funds = sum(
[calculate_pool_reward(uint32(i)) + calculate_base_farmer_reward(uint32(i)) for i in range(1, num_blocks)]
Expand All @@ -569,7 +568,7 @@ async def test_wallet_tx_reorg(self, two_wallet_nodes):
await time_out_assert(5, wallet.get_confirmed_balance, funds)
for i in range(0, 2):
await full_node_api.farm_new_transaction_block(FarmNewBlockProtocol(32 * b"0"))
await time_out_assert(10, wallet_2.get_confirmed_balance, 1000)
await time_out_assert(5, wallet_2.get_confirmed_balance, 1000)

await time_out_assert(5, wallet_node.wallet_state_manager.blockchain.get_peak_height, 7)

Expand All @@ -584,7 +583,7 @@ async def test_wallet_tx_reorg(self, two_wallet_nodes):
await time_out_assert(7, full_node_api.full_node.blockchain.get_peak_height, 10)
await time_out_assert(7, wallet_node.wallet_state_manager.blockchain.get_peak_height, 10)

for i in range(0, num_blocks):
for i in range(0, num_blocks * 3):
await asyncio.sleep(1)
await full_node_api.farm_new_transaction_block(FarmNewBlockProtocol(32 * b"0"))

Expand Down

0 comments on commit 15d4938

Please sign in to comment.