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

[FAB-17624] Handle net.Listen error in gossip unit test #863

Merged
merged 1 commit into from
Mar 16, 2020

Conversation

yacovm
Copy link
Contributor

@yacovm yacovm commented Mar 16, 2020

The function createDiscoveryInstanceThatGossipsWithInterceptors attempts
to create a net.Listener which binds on an address, and it can fail
if the port is in use.

The code currently just prints the error and continues, and later on
panics with a nil pointer.

I changed the code so that it now panics and doesn't continue the flow
of the test.

Change-Id: Ie55317a79d8fab03ab2f64d1e4a016cc416397ee
Signed-off-by: yacovm yacovm@il.ibm.com

The function createDiscoveryInstanceThatGossipsWithInterceptors attempts
to create a net.Listener which binds on an address, and it can fail
if the port is in use.

The code currently just prints the error and continues, and later on
panics with a nil pointer.

I changed the code so that it now panics and doesn't continue the flow
of the test.

Change-Id: Ie55317a79d8fab03ab2f64d1e4a016cc416397ee
Signed-off-by: yacovm <yacovm@il.ibm.com>
@yacovm yacovm requested a review from a team as a code owner March 16, 2020 12:09
@yacovm yacovm merged commit 3affbf0 into hyperledger:master Mar 16, 2020
@yacovm yacovm deleted the FAB-17624 branch February 9, 2021 10:38
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.

2 participants