Skip to content

Commit 1fa6681

Browse files
Kaua-Klassmannsylvestre
authored andcommitted
fix: update tests to sort
1 parent c4107c4 commit 1fa6681

14 files changed

+121
-32
lines changed

tests/by-util/test_sort.rs

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -258,6 +258,14 @@ fn test_multiple_decimals_numeric() {
258258
);
259259
}
260260

261+
#[test]
262+
fn test_multiple_groupings_numeric() {
263+
test_helper(
264+
"multiple_groupings_numeric",
265+
&["-n", "--numeric-sort", "--sort=numeric", "--sort=n"],
266+
);
267+
}
268+
261269
#[test]
262270
fn test_numeric_with_trailing_invalid_chars() {
263271
test_helper(
@@ -2359,18 +2367,18 @@ _
23592367
__
23602368
1
23612369
_
2362-
2,5
2363-
_
23642370
2.4
23652371
___
2372+
2,5
2373+
_
23662374
2.,,3
23672375
__
23682376
2.4
23692377
___
2370-
2,,3
2371-
_
23722378
2.4
23732379
___
2380+
2,,3
2381+
_
23742382
1a
23752383
_
23762384
2b

tests/fixtures/sort/mixed_floats_ints_chars_numeric.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ CARAvan
2121
8.013
2222
45
2323
46.89
24-
576,446.88800000
25-
576,446.890
2624
4567.
2725
37800
26+
576,446.88800000
27+
576,446.890
2828
4798908.340000000000
2929
4798908.45
3030
4798908.8909800

tests/fixtures/sort/mixed_floats_ints_chars_numeric.expected.debug

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -67,18 +67,18 @@ __
6767
46.89
6868
_____
6969
_____
70-
576,446.88800000
71-
___
72-
________________
73-
576,446.890
74-
___
75-
___________
7670
4567.
7771
_____
7872
____________________
7973
>>>>37800
8074
_____
8175
_________
76+
576,446.88800000
77+
___
78+
________________
79+
576,446.890
80+
___
81+
___________
8282
4798908.340000000000
8383
____________________
8484
____________________

tests/fixtures/sort/mixed_floats_ints_chars_numeric_stable.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ CARAvan
2424
8.013
2525
45
2626
46.89
27-
576,446.890
28-
576,446.88800000
2927
4567.
3028
37800
29+
576,446.88800000
30+
576,446.890
3131
4798908.340000000000
3232
4798908.45
3333
4798908.8909800

tests/fixtures/sort/mixed_floats_ints_chars_numeric_stable.expected.debug

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,14 +50,14 @@ _____
5050
__
5151
46.89
5252
_____
53-
576,446.890
54-
___
55-
576,446.88800000
56-
___
5753
4567.
5854
_____
5955
>>>>37800
6056
_____
57+
576,446.88800000
58+
___
59+
576,446.890
60+
___
6161
4798908.340000000000
6262
____________________
6363
4798908.45

tests/fixtures/sort/mixed_floats_ints_chars_numeric_unique.expected

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@
1111
8.013
1212
45
1313
46.89
14-
576,446.890
1514
4567.
1615
37800
16+
576,446.88800000
17+
576,446.890
1718
4798908.340000000000
1819
4798908.45
1920
4798908.8909800

tests/fixtures/sort/mixed_floats_ints_chars_numeric_unique.expected.debug

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,14 @@ _____
2424
__
2525
46.89
2626
_____
27-
576,446.890
28-
___
2927
4567.
3028
_____
3129
>>>>37800
3230
_____
31+
576,446.88800000
32+
___
33+
576,446.890
34+
___
3335
4798908.340000000000
3436
____________________
3537
4798908.45

tests/fixtures/sort/mixed_floats_ints_chars_numeric_unique_reverse.expected

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
4798908.8909800
22
4798908.45
33
4798908.340000000000
4+
576,446.890
5+
576,446.88800000
46
37800
57
4567.
6-
576,446.890
78
46.89
89
45
910
8.013

tests/fixtures/sort/mixed_floats_ints_chars_numeric_unique_reverse.expected.debug

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,14 @@ _______________
44
__________
55
4798908.340000000000
66
____________________
7+
576,446.890
8+
___
9+
576,446.88800000
10+
___
711
>>>>37800
812
_____
913
4567.
1014
_____
11-
576,446.890
12-
___
1315
46.89
1416
_____
1517
45

tests/fixtures/sort/multiple_decimals_numeric.expected

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,15 @@ CARAvan
2121
8.013
2222
45
2323
46.89
24-
576,446.88800000
25-
576,446.890
2624
4567..457
2725
4567.
2826
4567.1
2927
4567.34
3028
37800
3129
45670.89079.098
3230
45670.89079.1
31+
576,446.88800000
32+
576,446.890
3333
4798908.340000000000
3434
4798908.45
3535
4798908.8909800

0 commit comments

Comments
 (0)