-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make localnet tests more robust #293
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ClaytonNorthey92
requested review from
jcvernaleo,
max-sanchez,
marcopeereboom and
joshuasing
October 24, 2024 01:33
ClaytonNorthey92
force-pushed
the
clayton/robust-localnet-tests
branch
from
October 25, 2024 13:56
91fa0a1
to
387a630
Compare
ClaytonNorthey92
changed the title
increase initial number of blocks to 3000 in localnet
make localnet tests more robust
Oct 25, 2024
prior, localnet would wait a certain period of time, then check if we reached certain values of different resoruces in our local chain (ex. HEMI balance, pop txs mined). this was problematic because there was no guarantee that we would reach those within the given amount of time for various reasons. we could simply increase the time we wait, but then we would have to wait that amount of time per test. now, set a max timeout of 10 minutes for the test + 2 minute warm up. poll the network every 10 seconds for values reaching a reasonable threshold. if we reach this threshold within the timeout, success! otherwise failure.
ClaytonNorthey92
force-pushed
the
clayton/robust-localnet-tests
branch
from
October 25, 2024 14:04
387a630
to
03267a9
Compare
@@ -15,6 +15,7 @@ services: | |||
- "-rpcallowip=0.0.0.0/0" | |||
- "-rpcbind=0.0.0.0:18443" | |||
- "-txindex=1" | |||
- "-rpcworkqueue=400" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is likely not needed, but it doesn't hurt; I was seeing a few warnings of it being too small to handle requests so I bumped it up
joshuasing
approved these changes
Oct 25, 2024
jcvernaleo
approved these changes
Oct 25, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK
web3cryptoguy
pushed a commit
to web3cryptoguy/heminetwork
that referenced
this pull request
Nov 1, 2024
prior, localnet would wait a certain period of time, then check if we reached certain values of different resoruces in our local chain (ex. HEMI balance, pop txs mined). this was problematic because there was no guarantee that we would reach those within the given amount of time for various reasons. we could simply increase the time we wait, but then we would have to wait that amount of time per test. now, set a max timeout of 10 minutes for the test + 2 minute warm up. poll the network every 10 seconds for values reaching a reasonable threshold. if we reach this threshold within the timeout, success! otherwise failure.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
make localnet tests more robust
prior, localnet would wait a certain period of time, then check if we reached certain values of different resoruces in our local chain (ex. HEMI balance, pop txs mined). this was problematic because there was no guarantee that we would reach those within the given amount of time for various reasons.
we could simply increase the time we wait, but then we would have to wait that amount of time per test.
Changes
now, set a max timeout of 10 minutes for the test + 2 minute warm up. poll the network every 10 seconds for values reaching a reasonable threshold. if we reach this threshold within the timeout, success! otherwise failure.