Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions hathor/simulator/simulator.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ def _apply_patches(cls):

def verify_pow(self: BaseTransaction, *args: Any, **kwargs: Any) -> None:
assert self.hash is not None
logger.new().debug('Skipping BaseTransaction.verify_pow() for simulator')

cls._original_verify_pow = BaseTransaction.verify_pow
BaseTransaction.verify_pow = verify_pow
Expand Down
4 changes: 4 additions & 0 deletions tests/simulation/test_trigger.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ def setUp(self):
print('Simulation seed config:', self.simulator.seed)
print('-' * 30)

def tearDown(self):
super().tearDown()
self.simulator.stop()

def test_stop_after_n_mined_blocks(self):
miner1 = self.simulator.create_miner(self.manager1, hashpower=1e6)
miner1.start()
Expand Down