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

[DO NOT MERGE] testing flaky tests #1260

Closed
wants to merge 3 commits into from
Closed
Changes from 2 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
14 changes: 8 additions & 6 deletions protocol/daemons/slinky/client/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,14 @@ func TestClient(t *testing.T) {
)

defer grpcServer.Stop()
go func() {
ls, err := net.Listen("tcp", appFlags.GrpcAddress)
require.NoError(t, err)
err = grpcServer.Serve(ls)
require.NoError(t, err)
}()
/*
go func() {
ls, err := net.Listen("tcp", appFlags.GrpcAddress)
require.NoError(t, err)
err = grpcServer.Serve(ls)
require.NoError(t, err)
}()
*/
Comment on lines +46 to +53
Copy link
Contributor

Choose a reason for hiding this comment

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

The changes from lines 47 to 54 involve commenting out the gRPC server setup within a goroutine. While this might be an attempt to address flaky tests, it's essential to investigate the root cause of the flakiness. Disabling parts of the test setup can reduce the test's effectiveness in simulating real-world scenarios. Consider alternative solutions that maintain the integrity of the test setup, such as adjusting timeouts, using more deterministic data, or isolating external dependencies.

Would you like assistance in exploring alternative solutions to address the test flakiness while keeping the test setup intact?


slinky.On("Stop").Return(nil)
slinky.On("Start", mock.Anything).Return(nil).Once()
Expand Down
Loading