mirror of
https://github.com/go-kratos/kratos.git
synced 2025-09-16 09:16:35 +02:00
chore: remove the dependency of grpc_testing module (#2824)
This commit is contained in:
@@ -9,7 +9,6 @@ import (
|
||||
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/status"
|
||||
"google.golang.org/grpc/test/grpc_testing"
|
||||
)
|
||||
|
||||
type TestError struct{ message string }
|
||||
@@ -56,7 +55,7 @@ func TestErrors(t *testing.T) {
|
||||
t.Errorf("got %+v want %+v", se, err)
|
||||
}
|
||||
|
||||
gs2, _ := status.New(codes.InvalidArgument, "bad request").WithDetails(&grpc_testing.Empty{})
|
||||
gs2 := status.New(codes.InvalidArgument, "bad request")
|
||||
se2 := FromError(gs2.Err())
|
||||
// codes.InvalidArgument should convert to http.StatusBadRequest
|
||||
if se2.Code != http.StatusBadRequest {
|
||||
|
Reference in New Issue
Block a user