update deps and tests
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
parent
e8150c474c
commit
70e58e881c
2
go.mod
2
go.mod
@ -50,7 +50,7 @@ require (
|
||||
go.unistack.org/micro-tracer-opentracing/v3 v3.10.1
|
||||
go.unistack.org/micro-wrapper-recovery/v3 v3.8.3
|
||||
go.unistack.org/micro-wrapper-sql/v3 v3.10.2
|
||||
go.unistack.org/micro/v3 v3.10.8
|
||||
go.unistack.org/micro/v3 v3.10.9
|
||||
golang.org/x/crypto v0.5.0 // indirect
|
||||
golang.org/x/time v0.3.0 // indirect
|
||||
google.golang.org/genproto v0.0.0-20230127162408-596548ed4efa // indirect
|
||||
|
4
go.sum
4
go.sum
@ -946,8 +946,8 @@ go.unistack.org/micro/v3 v3.9.18/go.mod h1:gI4RkJKHLPW7KV6h4+ZBOZD997MRvFRXMPQIH
|
||||
go.unistack.org/micro/v3 v3.10.1/go.mod h1:gI4RkJKHLPW7KV6h4+ZBOZD997MRvFRXMPQIHpozikI=
|
||||
go.unistack.org/micro/v3 v3.10.4/go.mod h1:gI4RkJKHLPW7KV6h4+ZBOZD997MRvFRXMPQIHpozikI=
|
||||
go.unistack.org/micro/v3 v3.10.5/go.mod h1:gI4RkJKHLPW7KV6h4+ZBOZD997MRvFRXMPQIHpozikI=
|
||||
go.unistack.org/micro/v3 v3.10.8 h1:vl8fHYgWp6WadvVy4LtJ8lc3e8Y0VrfBOU5EorZ3PIA=
|
||||
go.unistack.org/micro/v3 v3.10.8/go.mod h1:gI4RkJKHLPW7KV6h4+ZBOZD997MRvFRXMPQIHpozikI=
|
||||
go.unistack.org/micro/v3 v3.10.9 h1:o8gdlE5JC9b2sm89RmztQPHnP4thN6FkGZyrKrahxX8=
|
||||
go.unistack.org/micro/v3 v3.10.9/go.mod h1:gI4RkJKHLPW7KV6h4+ZBOZD997MRvFRXMPQIHpozikI=
|
||||
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20190506204251-e1dfcc566284/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
|
@ -7,9 +7,23 @@ import (
|
||||
"testing"
|
||||
|
||||
"github.com/golang/protobuf/ptypes/wrappers"
|
||||
pb "go.unistack.org/micro-tests/client/grpc/proto"
|
||||
"go.unistack.org/micro/v3/logger/unwrap"
|
||||
)
|
||||
|
||||
func TestProtoMessage(t *testing.T) {
|
||||
type Response struct {
|
||||
Val *pb.Response `logger:"take"`
|
||||
}
|
||||
val := &Response{Val: &pb.Response{Msg: "test"}}
|
||||
|
||||
buf := fmt.Sprintf("%#v", unwrap.Unwrap(val, unwrap.Tagged(true)))
|
||||
cmp := `&unwrap_test.Response{Val:(*helloworld.Response){Msg:"test"}}`
|
||||
if strings.Compare(buf, cmp) != 0 {
|
||||
t.Fatalf("not proper written \n%s\n%s", cmp, buf)
|
||||
}
|
||||
}
|
||||
|
||||
func TestWrappers(t *testing.T) {
|
||||
type CustomerInfo struct {
|
||||
MainPhone *wrappers.StringValue `logger:"take"`
|
||||
|
Loading…
x
Reference in New Issue
Block a user