wrrLocality is a helper that takes a proto message and returns a WrrLocalityProto with the proto message marshaled into a proto.Any as a child.
(t *testing.T, m proto.Message)
| 56 | // WrrLocalityProto with the proto message marshaled into a proto.Any as a |
| 57 | // child. |
| 58 | func wrrLocality(t *testing.T, m proto.Message) *v3wrrlocalitypb.WrrLocality { |
| 59 | return &v3wrrlocalitypb.WrrLocality{ |
| 60 | EndpointPickingPolicy: &v3clusterpb.LoadBalancingPolicy{ |
| 61 | Policies: []*v3clusterpb.LoadBalancingPolicy_Policy{ |
| 62 | { |
| 63 | TypedExtensionConfig: &v3corepb.TypedExtensionConfig{ |
| 64 | TypedConfig: testutils.MarshalAny(t, m), |
| 65 | }, |
| 66 | }, |
| 67 | }, |
| 68 | }, |
| 69 | } |
| 70 | } |
| 71 | |
| 72 | // clusterWithLBConfiguration returns a cluster resource with the proto message |
| 73 | // passed Marshaled to an any and specified through the load_balancing_policy |
no test coverage detected