Fixup tests

This commit is contained in:
freddygv 2021-04-13 16:08:41 -06:00
parent 50c7915156
commit e175b309fb
3 changed files with 20 additions and 0 deletions

View File

@ -3519,6 +3519,10 @@ func testAgent_RegisterService_UnmanagedConnectProxy(t *testing.T, extraHCL stri
LocalBindPort: 1235,
},
},
Mode: api.ProxyModeTransparent,
TransparentProxy: &api.TransparentProxyConfig{
OutboundListenerPort: 808,
},
},
}

View File

@ -46,6 +46,10 @@ func TestConnectProxyConfig_ToAPI(t *testing.T) {
LocalBindAddress: "127.10.10.10",
},
},
Mode: ProxyModeTransparent,
TransparentProxy: TransparentProxyConfig{
OutboundListenerPort: 808,
},
},
want: &api.AgentServiceConnectProxyConfig{
DestinationServiceName: "web",
@ -76,6 +80,10 @@ func TestConnectProxyConfig_ToAPI(t *testing.T) {
LocalBindAddress: "127.10.10.10",
},
},
Mode: api.ProxyModeTransparent,
TransparentProxy: &api.TransparentProxyConfig{
OutboundListenerPort: 808,
},
},
},
}

View File

@ -122,6 +122,10 @@ func TestStructsToAgentService(t *testing.T) {
LocalServiceAddress: "127.0.0.1",
LocalServicePort: 8181,
Upstreams: structs.TestUpstreams(t),
Mode: structs.ProxyModeTransparent,
TransparentProxy: structs.TransparentProxyConfig{
OutboundListenerPort: 808,
},
Config: map[string]interface{}{
"foo": "bar",
},
@ -138,6 +142,10 @@ func TestStructsToAgentService(t *testing.T) {
LocalServiceAddress: "127.0.0.1",
LocalServicePort: 8181,
Upstreams: structs.TestUpstreams(t).ToAPI(),
Mode: api.ProxyModeTransparent,
TransparentProxy: &api.TransparentProxyConfig{
OutboundListenerPort: 808,
},
Config: map[string]interface{}{
"foo": "bar",
},