Skip to content

Commit 6866e7c

Browse files
.
1 parent a6eea77 commit 6866e7c

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

cns/restserver/internalapi_test.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ func TestSyncHostNCVersion(t *testing.T) {
289289
t.Errorf("Unexpected imdsContainerStatus.HostVersion %s, expected host version should be 1 in string", imdsContainerStatus.HostVersion)
290290
}
291291
if imdsContainerStatus.CreateNetworkContainerRequest.Version != "1" {
292-
t.Errorf("Unexpected imdsContainerStatus.CreateNetworkContainerRequest.Version %s, expected VM version should remain 1 in string", imdsContainerStatus.CreateNetworkContainerRequest.Version)
292+
t.Errorf("Unexpected version %s, expected VM version should remain 1 in string", imdsContainerStatus.CreateNetworkContainerRequest.Version)
293293
}
294294
})
295295
}
@@ -1780,7 +1780,6 @@ func TestMustEnsureNoStaleNCs_PanicsWhenIPsFromStaleNCAreAssigned(t *testing.T)
17801780
})
17811781
}
17821782

1783-
// mockIMDSAdapter adapts the anonymous struct to implement the imdsClient interface
17841783
type mockIMDSAdapter struct {
17851784
mock *struct {
17861785
networkInterfaces func(_ context.Context) ([]imds.NetworkInterface, error)
@@ -1806,7 +1805,6 @@ func (m *mockIMDSAdapter) GetIMDSVersions(ctx context.Context) (*imds.APIVersion
18061805
}, nil
18071806
}
18081807

1809-
// Add this helper function before TestSyncHostNCVersion
18101808
func setupIMDSMockAPIsWithCustomIDs(svc *HTTPRestService, interfaceIDs []string) func() {
18111809
mockIMDS := &struct {
18121810
networkInterfaces func(_ context.Context) ([]imds.NetworkInterface, error)

0 commit comments

Comments
 (0)