Skip to content
This repository was archived by the owner on Oct 13, 2023. It is now read-only.
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions integration/network/service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,12 @@ func TestServiceWithDefaultAddressPoolInit(t *testing.T) {
assert.NilError(t, err)
t.Logf("%s: NetworkInspect: %+v", t.Name(), out)
assert.Assert(t, len(out.IPAM.Config) > 0)
assert.Equal(t, out.IPAM.Config[0].Subnet, "20.20.1.0/24")

// Also inspect ingress network and make sure its in the same subnet
out, err = cli.NetworkInspect(ctx, "ingress", types.NetworkInspectOptions{Verbose: true})

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[2019-10-23T17:08:36.806Z] integration/network/service_test.go:369:32:warning: undeclared name: ctx (gosimple)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess s/ctx/context.Background()/ or backport moby#38557

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hm.. no, looks like we need moby#39671

.... which is in the other PR 😂

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or just commit 56a68c1

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, that one is already backported

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hm.. perhaps it was not 🤔

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

arf; likely also moby#39332, which is also in the other PR

assert.NilError(t, err)
assert.Assert(t, len(out.IPAM.Config) > 0)
assert.Equal(t, out.IPAM.Config[0].Subnet, "20.20.0.0/24")

err = cli.ServiceRemove(context.Background(), serviceID)
Expand Down