You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit c47cf0a
Browse filesBrowse the repository at this point in the historyBrowse files
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
2
+
3
+
exports[`ConfigCacheTestCases optimization minify-object-enumeration exported tests should enumerate a string's UTF-16 code units 1`] =`"function(){return[[\\"0\\",\\"1\\"],[\\"a\\",\\"b\\"],[[\\"0\\",\\"a\\"]],[\\"\\\\ud800\\"],[],[],[]]}"`;
4
+
5
+
exports[`ConfigCacheTestCases optimization minify-object-enumeration exported tests should enumerate array literals without reading holes or length 1`] =`"function(){return[[\\"0\\",\\"2\\"],[10,30],[[\\"0\\",10],[\\"2\\",30]],[],[],[]]}"`;
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
2
+
3
+
exports[`ConfigTestCases optimization minify-object-enumeration exported tests should enumerate a string's UTF-16 code units 1`] =`"function(){return[[\\"0\\",\\"1\\"],[\\"a\\",\\"b\\"],[[\\"0\\",\\"a\\"]],[\\"\\\\ud800\\"],[],[],[]]}"`;
4
+
5
+
exports[`ConfigTestCases optimization minify-object-enumeration exported tests should enumerate array literals without reading holes or length 1`] =`"function(){return[[\\"0\\",\\"2\\"],[10,30],[[\\"0\\",10],[\\"2\\",30]],[],[],[]]}"`;
Copy file name to clipboardExpand all lines: test/unitCases/javascript/__snapshots__/printer.unittest.js.snap
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -713,7 +713,7 @@ exports[`syntax-printer improve phase should write less, printing the same: argu
713
713
714
714
exports[`syntax-printer improve phase should write less, printing the same: assignments opening the statement after a \`var\`, as its values 1`] = `"var k;function f(o){var a,b;console.log(a=o.x,b=o.y,a,b)}function g(o){var a;return console.log(a=o.x,a),a}function h(o){var a=o.x;return k=function(){return a}}function m(o){var a=o.x;try{console.log(a)}finally{console.log(a+1)}}f({x:1,y:2}),h({x:4}),m({x:5}),console.log(g({x:3}),k());"`;
715
715
716
-
exports[`syntax-printer improve phase should write less, printing the same: built-in calls and constructions on literals no one reads 1`] = `"Object.keys([1,,2]),console.log(1);"`;
716
+
exports[`syntax-printer improve phase should write less, printing the same: built-in calls and constructions on literals no one reads 1`] = `"console.log(1);"`;
717
717
718
718
exports[`syntax-printer improve phase should write less, printing the same: built-in globals and their properties no one reads 1`] = `"console.log(1);"`;
Copy file name to clipboardExpand all lines: test/unitCases/javascript/printer.unittest.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -2076,7 +2076,7 @@ const KEPT_CASES = [
2076
2076
["a RegExp pattern not a string", 'try { RegExp(1); console.log(1); } catch (e) { console.log(2); }'],
2077
2077
["a function returning a call in place of a function reading its own `this`, naming itself, holding a directive or declaring a parameter's name", 'var o = { m: function () { return function () { for (var i = 0; i < 2; i++) console.log(typeof this, i); }(); } }; o.m(); var f = function () { return function g() { for (var i = 0; i < 2; i++) console.log(typeof g, i); }(); }; f(); var h = function () { return function () { "use strict"; for (var i = 0; i < 2; i++) console.log(typeof this, i); }(); }; h(); var k = function (a) { return function () { for (var a in { x: 1, y: 2 }) console.log(a); }(); }; k(1);'],
2078
2078
["a count too large to run", 'try { new Uint8Array(1e9); console.log(1); } catch (e) { console.log(2); }'],
2079
-
["an argument no literal", "function f(a) { String(a); Object.keys({ [a]: 1 }); Object.keys({ get b() { return 1; } }); Object.keys({ __proto__: a }); Object.keys([a]); Object.keys({ b: a }, 0); } f([1]); console.log(1);"],
2079
+
["an argument no literal", "function f(a) { String(a); Object.keys({ [a]: 1 }); Object.keys({ get b() { return 1; } }); Object.keys({ __proto__: a }); Object.keys(a); Object.keys({ b: a }, 0); } f([1]); console.log(1);"],
2080
2080
["a built-in that runs code", 'eval("console.log(1)");'],
2081
2081
["a built-in global the program declares", "var Set = function () { console.log(1); }; new Set();"],
2082
2082
["a built-in call a `with` could rebind", "with ({ JSON: { parse: function () { console.log(1); } } }) JSON.parse(\"1\");"],
0 commit comments