File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ type Gateway struct {
1515 UUID string `json:"uuid,omitempty"`
1616 Name string `json:"name,omitempty"`
1717 Listeners []Listener `json:"listeners,omitempty"`
18+ Addresses []Address `json:"addresses,omitempty"`
1819}
1920
2021type Listener struct {
@@ -24,6 +25,11 @@ type Listener struct {
2425 AllowedRoutes interface {} `json:"allowedRoutes,omitempty"`
2526}
2627
28+ type Address struct {
29+ Type string `json:"type,omitempty"`
30+ Value string `json:"value,omitempty"`
31+ }
32+
2733// Gateways defines a collection of gateway objects.
2834type Gateways []Gateway
2935
Original file line number Diff line number Diff line change @@ -37,6 +37,12 @@ const gatewaysFixture string = `
3737 "protocol": "HTTPS",
3838 "allowedRoutes": {"namespaces": {"from": "All"}}
3939 }
40+ ],
41+ "addresses": [
42+ {
43+ "type": "IPAddress",
44+ "value": "172.22.108.207"
45+ }
4046 ]
4147 }
4248 ]
@@ -121,6 +127,12 @@ func TestGatewaysList(t *testing.T) {
121127 AllowedRoutes : map [string ]interface {}{"namespaces" : map [string ]interface {}{"from" : "All" }},
122128 },
123129 },
130+ Addresses : []api.Address {
131+ {
132+ Type : "IPAddress" ,
133+ Value : "172.22.108.207" ,
134+ },
135+ },
124136 },
125137 }
126138 handler := fakeHTTPServer {}
You can’t perform that action at this time.
0 commit comments