Skip to content

Commit

Permalink
sort expected values
Browse files Browse the repository at this point in the history
  • Loading branch information
QxBytes committed Jan 21, 2025
1 parent e11864a commit 34ee01b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion npm/pkg/dataplane/ipsets/ipsetmanager_windows_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,12 @@ func verifyHNSCache(t *testing.T, expected map[string]hcn.SetPolicySetting, hns
copyOfCachedObj := *cacheObj
copyOfCachedObj.Values = strings.Join(members, ",")

require.Equal(t, setObj, copyOfCachedObj, setName+" mismatch in cache")
expectedMembers := strings.Split(setObj.Values, ",")
sort.Strings(expectedMembers)
copyOfExpectedObj := setObj
copyOfExpectedObj.Values = strings.Join(expectedMembers, ",")

require.Equal(t, copyOfExpectedObj, copyOfCachedObj, setName+" mismatch in cache")
}
}

Expand Down

0 comments on commit 34ee01b

Please sign in to comment.