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

sauron: make tests more robust #649

Merged
merged 1 commit into from
Feb 7, 2025

Conversation

chrisguida
Copy link
Collaborator

@chrisguida chrisguida commented Feb 7, 2025

cln-grpc was dying and taking the rest of lightningd with it (because it's important) because it was trying to listen on port 9736 in multiple tests simlutaneously. this PR allows the sauron tests to take advantage of the new plyn-testing feature that assigns the grpc plugin a random unused port by default. sauron's tests were previously overriding these values in its override fixtures, and this PR corrects that. there is still some brittle- ness around the TEST_NETWORK global variable, but setting it in the override LightningNode fixture at the top of each test, immediately before the call to init the superclass, appears to make the tests pass, so we'll leave it like this for now.

we also remove the pin to pyln-client 24.05, as this requirement no longer seems necessary.

this fixes #618

cln-grpc was dying and taking the rest of lightningd with it
(because it's important) because it was trying to listen on port
9736 in multiple tests simlutaneously. this PR allows the sauron
tests to take advantage of the new plyn-testing feature that
assigns the grpc plugin a random unused port by default. sauron's
tests were previously overriding these values in its override
fixtures, and this PR corrects that. there is still some brittle-
ness around the `TEST_NETWORK` global variable, but setting it
in the override `LightningNode` fixture at the top of each test,
immediately before the call to init the superclass, appears to
make the tests pass, so we'll leave it like this for now.
@chrisguida chrisguida self-assigned this Feb 7, 2025
@chrisguida chrisguida merged commit e93fe8b into lightningd:master Feb 7, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sauron: Fix tests for compatibility with latest pyln-client version
1 participant