Skip to content

Commit b12afce

Browse files
test: re-key the oxc corpus lists to the bumped oxc tests, and file its new cases
oxc's test files gained cases and lost comments, so every entry keyed by a line in them moved; each is mapped through the diff between the two commits. The new cases oxc writes shorter join their file's group, and the new auto-accessor field joins REFUSED_BY_WEBPACK. Claude-Session: https://claude.ai/code/session_017TkBWTk3wcyUcJYDp5ZhaP
1 parent bce6c07 commit b12afce

2 files changed

Lines changed: 87 additions & 57 deletions

File tree

‎test/helpers/oxcSmaller.js‎

Lines changed: 76 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const OXC_SMALLER_BY_REASON = [
3535
"oxc minifier: peephole/dead_code_elimination.rs:886",
3636
"oxc minifier: peephole/fold_constants.rs:1360",
3737
"oxc minifier: peephole/minimize_statements.rs:32",
38-
"oxc minifier: peephole/substitute_alternate_syntax.rs:1072",
38+
"oxc minifier: peephole/substitute_alternate_syntax.rs:1086",
3939
"swc exec: concat_tpl_keeps_delimiter_after_interpolation",
4040
"swc exec: issue_11517_http_status",
4141
"swc exec: issue_4788_1",
@@ -211,8 +211,8 @@ const OXC_SMALLER_BY_REASON = [
211211
"oxc minifier: peephole/substitute_alternate_syntax.rs:168",
212212
"oxc minifier: peephole/substitute_alternate_syntax.rs:169",
213213
"oxc minifier: peephole/substitute_alternate_syntax.rs:715",
214-
"oxc minifier: peephole/substitute_alternate_syntax.rs:851",
215-
"oxc minifier: peephole/substitute_alternate_syntax.rs:873"
214+
"oxc minifier: peephole/substitute_alternate_syntax.rs:865",
215+
"oxc minifier: peephole/substitute_alternate_syntax.rs:887"
216216
]
217217
],
218218
[
@@ -261,24 +261,31 @@ const OXC_SMALLER_BY_REASON = [
261261
[
262262
"oxc evaluates more built-in methods called on constants, as oxc's `peephole/replace_known_methods.rs` tests show",
263263
[
264-
"oxc minifier: peephole/replace_known_methods.rs:1007",
265-
"oxc minifier: peephole/replace_known_methods.rs:1009",
266-
"oxc minifier: peephole/replace_known_methods.rs:1111",
264+
"oxc minifier: peephole/replace_known_methods.rs:1032",
265+
"oxc minifier: peephole/replace_known_methods.rs:1033",
266+
"oxc minifier: peephole/replace_known_methods.rs:1043",
267+
"oxc minifier: peephole/replace_known_methods.rs:1045",
268+
"oxc minifier: peephole/replace_known_methods.rs:1071",
269+
"oxc minifier: peephole/replace_known_methods.rs:1073",
270+
"oxc minifier: peephole/replace_known_methods.rs:1175",
267271
"oxc minifier: peephole/replace_known_methods.rs:178",
268272
"oxc minifier: peephole/replace_known_methods.rs:48",
269273
"oxc minifier: peephole/replace_known_methods.rs:49",
270274
"oxc minifier: peephole/replace_known_methods.rs:629",
271275
"oxc minifier: peephole/replace_known_methods.rs:630",
272276
"oxc minifier: peephole/replace_known_methods.rs:631",
273-
"oxc minifier: peephole/replace_known_methods.rs:841",
274-
"oxc minifier: peephole/replace_known_methods.rs:842",
275-
"oxc minifier: peephole/replace_known_methods.rs:843",
276-
"oxc minifier: peephole/replace_known_methods.rs:892",
277-
"oxc minifier: peephole/replace_known_methods.rs:893",
278-
"oxc minifier: peephole/replace_known_methods.rs:968",
279-
"oxc minifier: peephole/replace_known_methods.rs:969",
280-
"oxc minifier: peephole/replace_known_methods.rs:979",
281-
"oxc minifier: peephole/replace_known_methods.rs:981"
277+
"oxc minifier: peephole/replace_known_methods.rs:802",
278+
"oxc minifier: peephole/replace_known_methods.rs:803",
279+
"oxc minifier: peephole/replace_known_methods.rs:804",
280+
"oxc minifier: peephole/replace_known_methods.rs:805",
281+
"oxc minifier: peephole/replace_known_methods.rs:806",
282+
"oxc minifier: peephole/replace_known_methods.rs:808",
283+
"oxc minifier: peephole/replace_known_methods.rs:809",
284+
"oxc minifier: peephole/replace_known_methods.rs:905",
285+
"oxc minifier: peephole/replace_known_methods.rs:906",
286+
"oxc minifier: peephole/replace_known_methods.rs:907",
287+
"oxc minifier: peephole/replace_known_methods.rs:956",
288+
"oxc minifier: peephole/replace_known_methods.rs:957"
282289
]
283290
],
284291
[
@@ -307,34 +314,34 @@ const OXC_SMALLER_BY_REASON = [
307314
[
308315
"oxc writes conditions shorter, as oxc's `peephole/minimize_conditions.rs` tests show",
309316
[
310-
"oxc minifier: peephole/minimize_conditions.rs:1055",
311-
"oxc minifier: peephole/minimize_conditions.rs:1068",
317+
"oxc minifier: peephole/minimize_conditions.rs:1053",
318+
"oxc minifier: peephole/minimize_conditions.rs:1066",
312319
"oxc minifier: peephole/minimize_conditions.rs:113",
313-
"oxc minifier: peephole/minimize_conditions.rs:1206",
314-
"oxc minifier: peephole/minimize_conditions.rs:1226",
315-
"oxc minifier: peephole/minimize_conditions.rs:1245",
316-
"oxc minifier: peephole/minimize_conditions.rs:1254",
320+
"oxc minifier: peephole/minimize_conditions.rs:1204",
321+
"oxc minifier: peephole/minimize_conditions.rs:1224",
322+
"oxc minifier: peephole/minimize_conditions.rs:1243",
323+
"oxc minifier: peephole/minimize_conditions.rs:1252",
324+
"oxc minifier: peephole/minimize_conditions.rs:1292",
325+
"oxc minifier: peephole/minimize_conditions.rs:1293",
317326
"oxc minifier: peephole/minimize_conditions.rs:1294",
318327
"oxc minifier: peephole/minimize_conditions.rs:1295",
319328
"oxc minifier: peephole/minimize_conditions.rs:1296",
320-
"oxc minifier: peephole/minimize_conditions.rs:1297",
321329
"oxc minifier: peephole/minimize_conditions.rs:1298",
322-
"oxc minifier: peephole/minimize_conditions.rs:1300",
330+
"oxc minifier: peephole/minimize_conditions.rs:1305",
331+
"oxc minifier: peephole/minimize_conditions.rs:1306",
323332
"oxc minifier: peephole/minimize_conditions.rs:1307",
324333
"oxc minifier: peephole/minimize_conditions.rs:1308",
325334
"oxc minifier: peephole/minimize_conditions.rs:1309",
326335
"oxc minifier: peephole/minimize_conditions.rs:1310",
327-
"oxc minifier: peephole/minimize_conditions.rs:1311",
328-
"oxc minifier: peephole/minimize_conditions.rs:1312",
336+
"oxc minifier: peephole/minimize_conditions.rs:1313",
337+
"oxc minifier: peephole/minimize_conditions.rs:1314",
329338
"oxc minifier: peephole/minimize_conditions.rs:1315",
330339
"oxc minifier: peephole/minimize_conditions.rs:1316",
331340
"oxc minifier: peephole/minimize_conditions.rs:1317",
332341
"oxc minifier: peephole/minimize_conditions.rs:1318",
333342
"oxc minifier: peephole/minimize_conditions.rs:1319",
334-
"oxc minifier: peephole/minimize_conditions.rs:1320",
335-
"oxc minifier: peephole/minimize_conditions.rs:1321",
336-
"oxc minifier: peephole/minimize_conditions.rs:1325",
337-
"oxc minifier: peephole/minimize_conditions.rs:1407",
343+
"oxc minifier: peephole/minimize_conditions.rs:1323",
344+
"oxc minifier: peephole/minimize_conditions.rs:1405",
338345
"oxc minifier: peephole/minimize_conditions.rs:158",
339346
"oxc minifier: peephole/minimize_conditions.rs:163",
340347
"oxc minifier: peephole/minimize_conditions.rs:166",
@@ -379,16 +386,24 @@ const OXC_SMALLER_BY_REASON = [
379386
[
380387
"oxc drops more unused expressions, as oxc's `peephole/remove_unused_expression.rs` tests show",
381388
[
382-
"oxc minifier: peephole/remove_unused_expression.rs:1057",
383-
"oxc minifier: peephole/remove_unused_expression.rs:1157",
384-
"oxc minifier: peephole/remove_unused_expression.rs:135",
385-
"oxc minifier: peephole/remove_unused_expression.rs:136",
386-
"oxc minifier: peephole/remove_unused_expression.rs:446",
387-
"oxc minifier: peephole/remove_unused_expression.rs:560",
388-
"oxc minifier: peephole/remove_unused_expression.rs:589",
389-
"oxc minifier: peephole/remove_unused_expression.rs:692",
390-
"oxc minifier: peephole/remove_unused_expression.rs:918",
391-
"oxc minifier: peephole/remove_unused_expression.rs:92"
389+
"oxc minifier: peephole/remove_unused_expression.rs:1030",
390+
"oxc minifier: peephole/remove_unused_expression.rs:1169",
391+
"oxc minifier: peephole/remove_unused_expression.rs:1269",
392+
"oxc minifier: peephole/remove_unused_expression.rs:160",
393+
"oxc minifier: peephole/remove_unused_expression.rs:203",
394+
"oxc minifier: peephole/remove_unused_expression.rs:204",
395+
"oxc minifier: peephole/remove_unused_expression.rs:514",
396+
"oxc minifier: peephole/remove_unused_expression.rs:592",
397+
"oxc minifier: peephole/remove_unused_expression.rs:593",
398+
"oxc minifier: peephole/remove_unused_expression.rs:594",
399+
"oxc minifier: peephole/remove_unused_expression.rs:595",
400+
"oxc minifier: peephole/remove_unused_expression.rs:636",
401+
"oxc minifier: peephole/remove_unused_expression.rs:665",
402+
"oxc minifier: peephole/remove_unused_expression.rs:767",
403+
"oxc minifier: peephole/remove_unused_expression.rs:777",
404+
"oxc minifier: peephole/remove_unused_expression.rs:787",
405+
"oxc minifier: peephole/remove_unused_expression.rs:792",
406+
"oxc minifier: peephole/remove_unused_expression.rs:804"
392407
]
393408
],
394409
[
@@ -640,9 +655,10 @@ const OXC_SMALLER_BY_REASON = [
640655
"oxc minifier: peephole/inline_single_use_variable.rs:258",
641656
"oxc minifier: peephole/inline_single_use_variable.rs:282",
642657
"oxc minifier: peephole/inline_single_use_variable.rs:286",
643-
"oxc minifier: peephole/inline_single_use_variable.rs:338",
644-
"oxc minifier: peephole/inline_single_use_variable.rs:348",
645-
"oxc minifier: peephole/inline_single_use_variable.rs:400",
658+
"oxc minifier: peephole/inline_single_use_variable.rs:324",
659+
"oxc minifier: peephole/inline_single_use_variable.rs:349",
660+
"oxc minifier: peephole/inline_single_use_variable.rs:359",
661+
"oxc minifier: peephole/inline_single_use_variable.rs:411",
646662
"oxc minifier: peephole/inline_single_use_variable.rs:47",
647663
"oxc minifier: peephole/inline_single_use_variable.rs:80"
648664
]
@@ -735,8 +751,8 @@ const OXC_SMALLER_BY_REASON = [
735751
[
736752
"oxc drops more unreachable code, as oxc's `peephole/remove_dead_code.rs` tests show",
737753
[
738-
"oxc minifier: peephole/remove_dead_code.rs:224",
739-
"oxc minifier: peephole/remove_dead_code.rs:256"
754+
"oxc minifier: peephole/remove_dead_code.rs:263",
755+
"oxc minifier: peephole/remove_dead_code.rs:295"
740756
]
741757
],
742758
[
@@ -770,7 +786,20 @@ const OXC_SMALLER_BY_REASON = [
770786
],
771787
[
772788
"oxc's own integration cases, several transforms combined, as oxc's `peephole/oxc.rs` tests show",
773-
["oxc minifier: peephole/oxc.rs:23", "oxc minifier: peephole/oxc.rs:32"]
789+
[
790+
"oxc minifier: peephole/oxc.rs:100",
791+
"oxc minifier: peephole/oxc.rs:101",
792+
"oxc minifier: peephole/oxc.rs:102",
793+
"oxc minifier: peephole/oxc.rs:103",
794+
"oxc minifier: peephole/oxc.rs:104",
795+
"oxc minifier: peephole/oxc.rs:105",
796+
"oxc minifier: peephole/oxc.rs:106",
797+
"oxc minifier: peephole/oxc.rs:107",
798+
"oxc minifier: peephole/oxc.rs:108",
799+
"oxc minifier: peephole/oxc.rs:109",
800+
"oxc minifier: peephole/oxc.rs:23",
801+
"oxc minifier: peephole/oxc.rs:32"
802+
]
774803
],
775804
[
776805
"oxc inlines a function into its call site, where terser keeps the call",
@@ -843,8 +872,8 @@ const OXC_SMALLER_BY_REASON = [
843872
"oxc minifier: ecmascript/may_have_side_effects.rs:445",
844873
"oxc minifier: ecmascript/may_have_side_effects.rs:451",
845874
"oxc minifier: ecmascript/may_have_side_effects.rs:816",
846-
"oxc minifier: peephole/remove_unused_expression.rs:738",
847-
"oxc minifier: peephole/remove_unused_expression.rs:753"
875+
"oxc minifier: peephole/remove_unused_expression.rs:850",
876+
"oxc minifier: peephole/remove_unused_expression.rs:865"
848877
]
849878
],
850879
[

‎test/specCases/minify-corpora.spectest.js‎

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1207,22 +1207,23 @@ const REFUSED_BY_WEBPACK = {
12071207
"oxc minifier: mangler/property_mangler.rs:311": AUTO_ACCESSOR,
12081208
"oxc minifier: peephole/remove_unused_declaration.rs:356": AUTO_ACCESSOR,
12091209
"oxc minifier: peephole/remove_unused_declaration.rs:357": AUTO_ACCESSOR,
1210-
"oxc minifier: peephole/remove_unused_expression.rs:756": AUTO_ACCESSOR,
1211-
"oxc minifier: peephole/remove_unused_expression.rs:757": AUTO_ACCESSOR,
1212-
"oxc minifier: peephole/remove_unused_expression.rs:863": AUTO_ACCESSOR,
1210+
"oxc minifier: peephole/remove_unused_expression.rs:868": AUTO_ACCESSOR,
1211+
"oxc minifier: peephole/remove_unused_expression.rs:869": AUTO_ACCESSOR,
1212+
"oxc minifier: peephole/remove_unused_expression.rs:975": AUTO_ACCESSOR,
12131213
"oxc minifier: peephole/remove_unused_private_members.rs:49": AUTO_ACCESSOR,
12141214
"oxc minifier: peephole/remove_unused_private_members.rs:53": AUTO_ACCESSOR,
1215-
"oxc minifier: peephole/replace_known_methods.rs:1260": INVALID_PATTERN,
1216-
"oxc minifier: peephole/replace_known_methods.rs:1262": INVALID_PATTERN,
1215+
"oxc minifier: peephole/replace_known_methods.rs:1324": INVALID_PATTERN,
1216+
"oxc minifier: peephole/replace_known_methods.rs:1326": INVALID_PATTERN,
12171217
"oxc minifier: peephole/substitute_alternate_syntax.rs:705": AUTO_ACCESSOR,
12181218
"oxc minifier: peephole/substitute_alternate_syntax.rs:718": AUTO_ACCESSOR,
12191219
"oxc minifier: peephole/substitute_alternate_syntax.rs:720": AUTO_ACCESSOR,
1220-
"oxc minifier: peephole/substitute_alternate_syntax.rs:737": AUTO_ACCESSOR,
1221-
"oxc minifier: peephole/substitute_alternate_syntax.rs:742": AUTO_ACCESSOR,
1222-
"oxc minifier: peephole/substitute_alternate_syntax.rs:744": AUTO_ACCESSOR,
1223-
"oxc minifier: peephole/substitute_alternate_syntax.rs:746": AUTO_ACCESSOR,
1224-
"oxc minifier: peephole/substitute_alternate_syntax.rs:757": AUTO_ACCESSOR,
1220+
"oxc minifier: peephole/substitute_alternate_syntax.rs:734": AUTO_ACCESSOR,
1221+
"oxc minifier: peephole/substitute_alternate_syntax.rs:751": AUTO_ACCESSOR,
1222+
"oxc minifier: peephole/substitute_alternate_syntax.rs:756": AUTO_ACCESSOR,
1223+
"oxc minifier: peephole/substitute_alternate_syntax.rs:758": AUTO_ACCESSOR,
12251224
"oxc minifier: peephole/substitute_alternate_syntax.rs:760": AUTO_ACCESSOR,
1225+
"oxc minifier: peephole/substitute_alternate_syntax.rs:771": AUTO_ACCESSOR,
1226+
"oxc minifier: peephole/substitute_alternate_syntax.rs:774": AUTO_ACCESSOR,
12261227
"swc minifier: fixture/issues/11133/input.js": REDECLARED,
12271228
"terser compress: class-properties/parens_in": PRIVATE_UNDECLARED,
12281229
"terser compress: class-properties/parens_in_10": PRIVATE_UNDECLARED,

0 commit comments

Comments
 (0)