File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ package example_commands_test
5
5
import (
6
6
"context"
7
7
"fmt"
8
+ "sort"
8
9
9
10
"github.com/redis/go-redis/v9"
10
11
)
@@ -244,8 +245,12 @@ func ExampleClient_vectorset() {
244
245
panic (err )
245
246
}
246
247
248
+ sort .Slice (res23 , func (i , j int ) bool {
249
+ return res23 [i ].Name < res23 [j ].Name
250
+ })
251
+
247
252
fmt .Println (res23 )
248
- // >>> [{pt:A 1} {pt:E 0.8535534143447876 } {pt:D 0.5} {pt:C 0.5 }]
253
+ // >>> [{pt:A 1} {pt:C 0.5 } {pt:D 0.5} {pt:E 0.8535534143447876 }]
249
254
// STEP_END
250
255
251
256
// STEP_START vsim_filter
@@ -365,7 +370,7 @@ func ExampleClient_vectorset() {
365
370
// true
366
371
// 5
367
372
// [pt:E pt:A pt:D pt:C pt:B]
368
- // [{pt:A 1} {pt:E 0.8535534143447876 } {pt:D 0.5} {pt:C 0.5 }]
373
+ // [{pt:A 1} {pt:C 0.5 } {pt:D 0.5} {pt:E 0.8535534143447876 }]
369
374
// true
370
375
// true
371
376
// true
You can’t perform that action at this time.
0 commit comments