diff --git a/internal/host/plugin/repository_host_test.go b/internal/host/plugin/repository_host_test.go index 1f9f72a686..e2caef7f2c 100644 --- a/internal/host/plugin/repository_host_test.go +++ b/internal/host/plugin/repository_host_test.go @@ -221,6 +221,9 @@ func TestJob_UpsertHosts(t *testing.T) { cmpopts.SortSlices(func(x, y *Host) bool { return x.GetPublicId() < y.GetPublicId() }), + cmpopts.SortSlices(func(x, y string) bool { + return x < y + }), ), ) @@ -242,6 +245,9 @@ func TestJob_UpsertHosts(t *testing.T) { cmpopts.SortSlices(func(x, y *Host) bool { return x.GetPublicId() < y.GetPublicId() }), + cmpopts.SortSlices(func(x, y string) bool { + return x < y + }), ), ) plg := plg @@ -274,6 +280,9 @@ func TestJob_UpsertHosts(t *testing.T) { got, cmpopts.IgnoreUnexported(Host{}, store.Host{}), cmpopts.IgnoreTypes(×tamp.Timestamp{}), + cmpopts.SortSlices(func(x, y string) bool { + return x < y + }), ), ) assert.Empty(