From 505d3d7aeb15362389e2d14ab4def2453b15f9ec Mon Sep 17 00:00:00 2001 From: Tim Vaillancourt Date: Wed, 6 Nov 2024 17:34:12 +0100 Subject: [PATCH] sort expected tablets Signed-off-by: Tim Vaillancourt --- go/vt/topo/tablet_test.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/go/vt/topo/tablet_test.go b/go/vt/topo/tablet_test.go index 40b894816de..0017e7379ec 100644 --- a/go/vt/topo/tablet_test.go +++ b/go/vt/topo/tablet_test.go @@ -377,6 +377,9 @@ func TestServerGetTabletsByCell(t *testing.T) { slices.SortFunc(out, func(i, j *topo.TabletInfo) int { return cmp.Compare(i.Alias.Uid, j.Alias.Uid) }) + slices.SortFunc(tt.expectedTablets, func(i, j *topo.TabletInfo) int { + return cmp.Compare(i.Alias.Uid, j.Alias.Uid) + }) for i, tablet := range out { expected := tt.expectedTablets[i]