Skip to content
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

test: add in memory dns cache. #879

Merged
merged 2 commits into from
Dec 6, 2023
Merged

Conversation

nodech
Copy link
Contributor

@nodech nodech commented Dec 5, 2023

Several tests send DNS queries in order to construct claims, this allows to cache messages per question in memory so the same requests are not sent twice. Should reduce total time for the tests.

@nodech nodech added enhancement general - improving existing feature tests part of the codebase labels Dec 5, 2023
When actively woring on the claim related test cases, setting
HSD_TEST_DNS_FILE_CACHE=true will cache the requests locally.
NOTE: the cache does not have any expiration logic.
Copy link
Member

@rithvikvibhu rithvikvibhu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! saves ~1-3 mins in tests

@nodech nodech merged commit c9e3985 into handshake-org:master Dec 6, 2023
6 checks passed
@nodech nodech deleted the cache-test-dns branch December 6, 2023 11:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement general - improving existing feature tests part of the codebase
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants