-
Notifications
You must be signed in to change notification settings - Fork 969
Closed
Description
Environment
- Server: Dubbo-go, v3.1.1
- Client: Dubbo-go, v3.1.1
Issue description
When submitting PR, there is a certain probability that this test case will go wrong.
There is a contradiction in its logic.
t.Run("sum_error", func(t *testing.T) {
stream, err := client.Sum(context.Background())
assert.Nil(t, err)
// If this assertion is passed, an error will be reported in the following case
if sendErr := stream.Send(&pingv1.SumRequest{Number: 1}); sendErr != nil {
assert.ErrorIs(t, err, io.EOF) // mey sendErr
assert.Equal(t, triple.CodeOf(err), triple.CodeUnknown) // mey sendErr
}
err = stream.CloseAndReceive(triple.NewResponse(&pingv1.SumResponse{}))
assert.Equal(t, triple.CodeOf(err), triple.CodeInvalidArgument)
})
code link
Logs
Click me to check logs
Copy logs to here.
chickenlj
Metadata
Metadata
Assignees
Labels
No labels