Skip to content

Commit

Permalink
api: fix intrange linter warning in test code
Browse files Browse the repository at this point in the history
   for loop can be changed to `i := range expected` (intrange)

Signed-off-by: Roman Khimov <[email protected]>
  • Loading branch information
roman-khimov committed Oct 1, 2024
1 parent e995083 commit eefbb60
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/handler/encryption_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ func equalDataSlices(t *testing.T, expected, actual []byte) {
return
}

for i := range len(expected) {
for i := range expected {
if expected[i] != actual[i] {
require.Equalf(t, expected[i], actual[i], "differ start with '%d' position, length: %d", i, len(expected))
}
Expand Down

0 comments on commit eefbb60

Please sign in to comment.