MCPcopy Create free account
hub / github.com/chainloop-dev/chainloop / toGRPCStatus

Function toGRPCStatus

app/cli/main_test.go:31–33  ·  view source on GitHub ↗

toGRPCStatus converts a Kratos *errors.Error into a *status.Status the same way it would travel over the wire: Kratos Error -> GRPCStatus() -> gRPC Status.

(err *kratosErrors.Error)

Source from the content-addressed store, hash-verified

29// toGRPCStatus converts a Kratos *errors.Error into a *status.Status the same
30// way it would travel over the wire: Kratos Error -> GRPCStatus() -> gRPC Status.
31func toGRPCStatus(err *kratosErrors.Error) *status.Status {
32 return err.GRPCStatus()
33}
34
35func TestIsWrappedErr(t *testing.T) {
36 tests := []struct {

Callers 3

TestIsWrappedErrFunction · 0.85
TestIsUnmatchedAuthErrFunction · 0.85

Calls 1

GRPCStatusMethod · 0.80

Tested by

no test coverage detected