From 4722ef606dccb54d617438733d03c8add2c0548d Mon Sep 17 00:00:00 2001 From: Jimmy Thomson Date: Wed, 27 Jun 2018 15:58:13 -0700 Subject: [PATCH] Updating test baselines --- lib/Common/ConfigFlagsList.h | 12 +- test/Date/DateGetSet.baseline | 6 - test/Date/DateGetSet.js | 19 +- ...tDebugUtilsAddPropertyType.js.dbg.baseline | 6 +- ...gExp_specialproperties_all.js.dbg.baseline | 2 +- ..._specialproperties_default.js.dbg.baseline | 2 +- ...cialproperties_with_sticky.js.dbg.baseline | 2 +- ...ialproperties_with_unicode.js.dbg.baseline | 2 +- ...const_trycatch_simple_fast.js.dbg.baseline | 18 +- .../attachWithDeferParse.js.dbg.baseline | 32 +-- .../DebuggerCommon/bug_543550.js.dbg.baseline | 4 +- .../catchInspection.js.dbg.baseline | 220 ++++++++--------- .../globalFuncVars.js.dbg.baseline | 224 +++++++++--------- test/DebuggerCommon/indexprop.js.dbg.baseline | 10 +- .../step_out_direct_attach.js.dbg.baseline | 4 +- ...rom_JITted_function_attach.js.dbg.baseline | 2 +- ...step_out_from_catch_attach.js.dbg.baseline | 2 +- test/Lib/error.baseline | 2 +- test/Lib/getclass1.baseline | 4 +- test/Prototypes/initProto.baseline | 8 +- test/Prototypes/initProto.js | 6 +- test/StackTrace/ErrorPrototype.baseline | 68 ++---- test/StackTrace/ErrorPrototype.js | 4 +- test/es6/regexflags.js | 4 +- 24 files changed, 314 insertions(+), 349 deletions(-) diff --git a/lib/Common/ConfigFlagsList.h b/lib/Common/ConfigFlagsList.h index 69d02590548..b0f187a1098 100644 --- a/lib/Common/ConfigFlagsList.h +++ b/lib/Common/ConfigFlagsList.h @@ -627,14 +627,7 @@ PHASE(All) #define DEFAULT_CONFIG_ES6StringPrototypeFixes (true) #define DEFAULT_CONFIG_ES2018ObjectSpread (false) -#ifndef DEFAULT_CONFIG_ES6PrototypeChain -#ifdef COMPILE_DISABLE_ES6PrototypeChain - // If ES6PrototypeChain needs to be disabled by compile flag, DEFAULT_CONFIG_ES6PrototypeChain should be false - #define DEFAULT_CONFIG_ES6PrototypeChain (false) -#else - #define DEFAULT_CONFIG_ES6PrototypeChain (true) -#endif -#endif +#define DEFAULT_CONFIG_ES6PrototypeChain (true) #define DEFAULT_CONFIG_ES6ToPrimitive (true) #define DEFAULT_CONFIG_ES6ToLength (true) @@ -1127,9 +1120,6 @@ FLAGPR (Boolean, ES6, ES6String , "Enable ES6 String exte FLAGPR (Boolean, ES6, ES6StringPrototypeFixes, "Enable ES6 String.prototype fixes" , DEFAULT_CONFIG_ES6StringPrototypeFixes) FLAGPR (Boolean, ES6, ES2018ObjectSpread , "Enable ES2018 Object Spread" , DEFAULT_CONFIG_ES2018ObjectSpread) -#ifndef COMPILE_DISABLE_ES6PrototypeChain - #define COMPILE_DISABLE_ES6PrototypeChain 0 -#endif FLAGPR_REGOVR_EXP(Boolean, ES6, ES6PrototypeChain , "Enable ES6 prototypes (Example: Date prototype is object)", DEFAULT_CONFIG_ES6PrototypeChain) FLAGPR (Boolean, ES6, ES6ToPrimitive , "Enable ES6 ToPrimitive symbol" , DEFAULT_CONFIG_ES6ToPrimitive) FLAGPR (Boolean, ES6, ES6ToLength , "Enable ES6 ToLength fixes" , DEFAULT_CONFIG_ES6ToLength) diff --git a/test/Date/DateGetSet.baseline b/test/Date/DateGetSet.baseline index 93a74652287..cdb68e880f3 100644 --- a/test/Date/DateGetSet.baseline +++ b/test/Date/DateGetSet.baseline @@ -84,9 +84,3 @@ toUTCString : Fri, 26 Jul 35816 03:06:07 GMT valueOf : 1068094436767008 toISOString method : function toJSON method : function -1905 -1904 -0 -1999 -1998 -5 diff --git a/test/Date/DateGetSet.js b/test/Date/DateGetSet.js index ca9052d5487..5e56bb440cf 100644 --- a/test/Date/DateGetSet.js +++ b/test/Date/DateGetSet.js @@ -183,14 +183,11 @@ WScript.Echo("valueOf : " + d.valueOf()) WScript.Echo("toISOString method : " + typeof d.toISOString); WScript.Echo("toJSON method : " + typeof d.toJSON); -// Set fullYear/fullYear+month/year on the Date prototype -Date.prototype.setYear(5); // Year -WScript.Echo(Date.prototype.getFullYear()); -Date.prototype.setYear(4, 4); // Year, month -- month should be ignored -WScript.Echo(Date.prototype.getFullYear()); -WScript.Echo(Date.prototype.getMonth()); -Date.prototype.setFullYear(1999); // Only full year -WScript.Echo(Date.prototype.getFullYear()); -Date.prototype.setFullYear(1998, 5); // Full year and month -WScript.Echo(Date.prototype.getFullYear()); -WScript.Echo(Date.prototype.getMonth()); +WScript.LoadScriptFile("..\\UnitTestFramework\\UnitTestFramework.js", "self"); + +assert.throws(() => Date.prototype.setYear(5), TypeError); +assert.throws(() => Date.prototype.getFullYear(), TypeError); +assert.throws(() => Date.prototype.setYear(4, 4), TypeError); +assert.throws(() => Date.prototype.getMonth(), TypeError); +assert.throws(() => Date.prototype.setFullYear(1999), TypeError); +assert.throws(() => Date.prototype.setFullYear(1998, 5), TypeError); diff --git a/test/Debugger/JsrtDebugUtilsAddPropertyType.js.dbg.baseline b/test/Debugger/JsrtDebugUtilsAddPropertyType.js.dbg.baseline index c5761a0808c..4f85acffd1e 100644 --- a/test/Debugger/JsrtDebugUtilsAddPropertyType.js.dbg.baseline +++ b/test/Debugger/JsrtDebugUtilsAddPropertyType.js.dbg.baseline @@ -61,7 +61,7 @@ "#__proto__": "Object {...}" }, "a19": { - "#__proto__": "RegExp ", + "#__proto__": "Object {...}", "lastIndex": "number 0", "global": "boolean false", "multiline": "boolean false", @@ -72,13 +72,13 @@ "sticky": "boolean false" }, "a20": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "description": "string Hello World!", "message": "string Hello World!", "stack": "string " }, "a21": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string Hello World!", "stack": "string " }, diff --git a/test/DebuggerCommon/ES6_RegExp_specialproperties_all.js.dbg.baseline b/test/DebuggerCommon/ES6_RegExp_specialproperties_all.js.dbg.baseline index 50a35df1c38..b6d775dc5e2 100644 --- a/test/DebuggerCommon/ES6_RegExp_specialproperties_all.js.dbg.baseline +++ b/test/DebuggerCommon/ES6_RegExp_specialproperties_all.js.dbg.baseline @@ -2,7 +2,7 @@ { "evaluate": { "r": { - "#__proto__": "RegExp ", + "#__proto__": "Object {...}", "lastIndex": "number 0", "global": "boolean false", "multiline": "boolean false", diff --git a/test/DebuggerCommon/ES6_RegExp_specialproperties_default.js.dbg.baseline b/test/DebuggerCommon/ES6_RegExp_specialproperties_default.js.dbg.baseline index f29e65364f6..0d3f1b6ef20 100644 --- a/test/DebuggerCommon/ES6_RegExp_specialproperties_default.js.dbg.baseline +++ b/test/DebuggerCommon/ES6_RegExp_specialproperties_default.js.dbg.baseline @@ -2,7 +2,7 @@ { "evaluate": { "r": { - "#__proto__": "RegExp ", + "#__proto__": "Object {...}", "lastIndex": "number 0", "global": "boolean false", "multiline": "boolean false", diff --git a/test/DebuggerCommon/ES6_RegExp_specialproperties_with_sticky.js.dbg.baseline b/test/DebuggerCommon/ES6_RegExp_specialproperties_with_sticky.js.dbg.baseline index c927524b5f2..e6ea8986be2 100644 --- a/test/DebuggerCommon/ES6_RegExp_specialproperties_with_sticky.js.dbg.baseline +++ b/test/DebuggerCommon/ES6_RegExp_specialproperties_with_sticky.js.dbg.baseline @@ -2,7 +2,7 @@ { "evaluate": { "r": { - "#__proto__": "RegExp ", + "#__proto__": "Object {...}", "lastIndex": "number 0", "global": "boolean false", "multiline": "boolean false", diff --git a/test/DebuggerCommon/ES6_RegExp_specialproperties_with_unicode.js.dbg.baseline b/test/DebuggerCommon/ES6_RegExp_specialproperties_with_unicode.js.dbg.baseline index d20dc960c8a..49cee437e81 100644 --- a/test/DebuggerCommon/ES6_RegExp_specialproperties_with_unicode.js.dbg.baseline +++ b/test/DebuggerCommon/ES6_RegExp_specialproperties_with_unicode.js.dbg.baseline @@ -2,7 +2,7 @@ { "evaluate": { "r": { - "#__proto__": "RegExp ", + "#__proto__": "Object {...}", "lastIndex": "number 0", "global": "boolean false", "multiline": "boolean false", diff --git a/test/DebuggerCommon/ES6_letconst_trycatch_simple_fast.js.dbg.baseline b/test/DebuggerCommon/ES6_letconst_trycatch_simple_fast.js.dbg.baseline index 4f2b6f24286..4fa3aa09a23 100644 --- a/test/DebuggerCommon/ES6_letconst_trycatch_simple_fast.js.dbg.baseline +++ b/test/DebuggerCommon/ES6_letconst_trycatch_simple_fast.js.dbg.baseline @@ -1,10 +1,10 @@ [ { "this": { + "callcount": "number 3", "Call": "function ", "bar": "function ", - "Run": "function ", - "callcount": "number 3" + "Run": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -16,18 +16,18 @@ "z": "number 1" }, "globals": { + "callcount": "number 3", "Call": "function ", "bar": "function ", - "Run": "function ", - "callcount": "number 3" + "Run": "function " } }, { "this": { + "callcount": "number 3", "Call": "function ", "bar": "function ", - "Run": "function ", - "callcount": "number 3" + "Run": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -37,7 +37,7 @@ }, "locals": { "e": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "number": "number 0", "description": "string ", "stack": "string " @@ -45,10 +45,10 @@ "z": "number 2" }, "globals": { + "callcount": "number 3", "Call": "function ", "bar": "function ", - "Run": "function ", - "callcount": "number 3" + "Run": "function " } } ] \ No newline at end of file diff --git a/test/DebuggerCommon/attachWithDeferParse.js.dbg.baseline b/test/DebuggerCommon/attachWithDeferParse.js.dbg.baseline index bc1d637faf5..37f826e8fb4 100644 --- a/test/DebuggerCommon/attachWithDeferParse.js.dbg.baseline +++ b/test/DebuggerCommon/attachWithDeferParse.js.dbg.baseline @@ -11,10 +11,10 @@ "Symbol.iterator": "function " }, "scopes0": { - "f1": "function ", - "g": "function ", "a": "number 10", - "s": "undefined undefined" + "s": "undefined undefined", + "f1": "function ", + "g": "function " }, "globals": { "foo": "function ", @@ -33,6 +33,8 @@ "Symbol.iterator": "function " }, "locals": { + "a": "number 10", + "s": "undefined undefined", "f1": { "#__proto__": "function ", "prototype": "Object {...}", @@ -48,9 +50,7 @@ "caller": "object null", "arguments": "object null", "length": "number 0" - }, - "a": "number 10", - "s": "undefined undefined" + } }, "globals": { "foo": "function ", @@ -70,36 +70,36 @@ }, "locals": { "t": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", "stack": "string " }, - "f1": { + "a": "number 10", + "s": { "#__proto__": "function ", "prototype": "Object {...}", - "name": "string f1", + "name": "string ", "caller": "object null", "arguments": "object null", - "length": "number 0" + "length": "number 2" }, - "g": { + "f1": { "#__proto__": "function ", "prototype": "Object {...}", - "name": "string g", + "name": "string f1", "caller": "object null", "arguments": "object null", "length": "number 0" }, - "a": "number 10", - "s": { + "g": { "#__proto__": "function ", "prototype": "Object {...}", - "name": "string ", + "name": "string g", "caller": "object null", "arguments": "object null", - "length": "number 2" + "length": "number 0" } }, "globals": { diff --git a/test/DebuggerCommon/bug_543550.js.dbg.baseline b/test/DebuggerCommon/bug_543550.js.dbg.baseline index 4799e1587da..f2671bb19ea 100644 --- a/test/DebuggerCommon/bug_543550.js.dbg.baseline +++ b/test/DebuggerCommon/bug_543550.js.dbg.baseline @@ -54,7 +54,7 @@ "name": "string set" }, "size": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string Map.prototype.size: 'this' is not a Map object", "description": "string Map.prototype.size: 'this' is not a Map object", "number": "number -2146823172", @@ -109,4 +109,4 @@ } } } -] +] \ No newline at end of file diff --git a/test/DebuggerCommon/catchInspection.js.dbg.baseline b/test/DebuggerCommon/catchInspection.js.dbg.baseline index f4dc9c27c6b..8454cbba81b 100644 --- a/test/DebuggerCommon/catchInspection.js.dbg.baseline +++ b/test/DebuggerCommon/catchInspection.js.dbg.baseline @@ -1,6 +1,8 @@ [ { "this": { + "top": "Object {...}", + "startTest": "undefined undefined", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -11,9 +13,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "undefined undefined" + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -35,6 +35,8 @@ "e": "Error " }, "globals": { + "top": "Object {...}", + "startTest": "undefined undefined", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -45,13 +47,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "undefined undefined" + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "undefined undefined", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -62,9 +64,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "undefined undefined" + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -86,6 +86,8 @@ "e": "Error " }, "globals": { + "top": "Object {...}", + "startTest": "undefined undefined", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -96,13 +98,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "undefined undefined" + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -113,9 +115,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -125,7 +125,7 @@ }, "locals": { "e": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -141,6 +141,8 @@ } }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -151,13 +153,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -168,9 +170,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -182,6 +182,8 @@ "e": "Error " }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -192,13 +194,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -209,9 +211,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -221,7 +221,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -232,6 +232,8 @@ "k": "number 10" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -242,13 +244,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -259,9 +261,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -271,7 +271,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -283,6 +283,8 @@ "k": "number 10" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -293,13 +295,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -310,9 +312,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -322,7 +322,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -334,6 +334,8 @@ "k": "number 10" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -344,13 +346,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -361,9 +363,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -373,7 +373,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -381,6 +381,8 @@ } }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -391,13 +393,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -408,9 +410,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -420,7 +420,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -428,6 +428,8 @@ } }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -438,13 +440,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -455,9 +457,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -467,7 +467,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -475,6 +475,8 @@ } }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -485,13 +487,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -502,9 +504,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -514,7 +514,7 @@ }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -523,6 +523,8 @@ "m1": "number 10" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -533,13 +535,13 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -550,18 +552,28 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "locals": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", "stack": "string " }, + "top": { + "#__proto__": "Object {...}", + "f1": "function " + }, + "startTest": { + "#__proto__": "function ", + "prototype": "Object {...}", + "name": "string ", + "caller": "object null", + "arguments": "object null", + "length": "number 0" + }, "bar": { "#__proto__": "function ", "prototype": "Object {...}", @@ -649,18 +661,6 @@ "caller": "object null", "arguments": "object null", "length": "number 0" - }, - "top": { - "#__proto__": "Object {...}", - "f1": "function " - }, - "startTest": { - "#__proto__": "function ", - "prototype": "Object {...}", - "name": "string ", - "caller": "object null", - "arguments": "object null", - "length": "number 0" } }, "globals": {} @@ -682,7 +682,7 @@ { "evaluate": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -693,7 +693,7 @@ { "evaluate": { "ex": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", @@ -730,6 +730,8 @@ }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -740,9 +742,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -760,6 +760,8 @@ "fa": "number 123" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -770,9 +772,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { @@ -799,6 +799,8 @@ }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -809,9 +811,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -823,6 +823,8 @@ "e1": "number -1" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -833,9 +835,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } }, { @@ -868,6 +868,8 @@ }, { "this": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -878,9 +880,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " }, "arguments": { "#__proto__": "Object {...}", @@ -895,6 +895,8 @@ "foo0": "number 12" }, "globals": { + "top": "Object {...}", + "startTest": "function ", "bar": "function ", "bar2": "function ", "foo": "function ", @@ -905,9 +907,7 @@ "foo3": "function ", "foo5": "function ", "foo6": "function ", - "foo7": "function ", - "top": "Object {...}", - "startTest": "function " + "foo7": "function " } } ] \ No newline at end of file diff --git a/test/DebuggerCommon/globalFuncVars.js.dbg.baseline b/test/DebuggerCommon/globalFuncVars.js.dbg.baseline index 64f4f1ed2a9..d72dd6e7f60 100644 --- a/test/DebuggerCommon/globalFuncVars.js.dbg.baseline +++ b/test/DebuggerCommon/globalFuncVars.js.dbg.baseline @@ -1,102 +1,104 @@ [ { "this": { + "obj": "undefined undefined", + "c": "undefined undefined", + "foo": "function ", + "bar": "function " + }, + "scopes0": { + "arguments": "Object {...}", + "mm": "Array [22,33]", + "f1": "function function f1() {}", + "a": "number 10", + "b": "Object {...}", + "c1": "undefined undefined" + }, + "globals": { + "obj": "undefined undefined", + "c": "undefined undefined", "foo": "function ", - "bar": "function ", + "bar": "function " + } + }, + { + "evaluate": { + "mm": "Array [22,33]" + } + }, + { + "callStack": [ + { + "line": 3, + "column": 1, + "sourceText": "ex1", + "function": "eval code" + }, + { + "line": 10, + "column": 4, + "sourceText": "eval(' try { \\n abc.def = 10;\\n } catch(ex1) { \\n ex1; /**bp:stack();locals(1);evaluate(\"ex1\");evaluate(\"c1\")**/ } \\nc;')", + "function": "foo" + }, + { + "line": 13, + "column": 0, + "sourceText": "foo()", + "function": "Global code" + } + ] + }, + { + "this": { "obj": "undefined undefined", - "c": "undefined undefined" + "c": "undefined undefined", + "foo": "function ", + "bar": "function " }, - "scopes0": { - "arguments": "Object {...}", - "mm": "Array [22,33]", - "f1": "function function f1() {}", - "a": "number 10", - "b": "Object {...}", - "c1": "undefined undefined" - }, - "globals": { - "foo": "function ", - "bar": "function ", - "obj": "undefined undefined", - "c": "undefined undefined" - } - }, - { - "evaluate": { - "mm": "Array [22,33]" - } - }, - { - "callStack": [ - { - "line": 3, - "column": 1, - "sourceText": "ex1", - "function": "eval code" - }, - { - "line": 10, - "column": 4, - "sourceText": "eval(' try { \\n abc.def = 10;\\n } catch(ex1) { \\n ex1; /**bp:stack();locals(1);evaluate(\"ex1\");evaluate(\"c1\")**/ } \\nc;')", - "function": "foo" - }, - { - "line": 13, - "column": 0, - "sourceText": "foo()", - "function": "Global code" - } - ] - }, - { - "this": { - "foo": "function ", - "bar": "function ", - "obj": "undefined undefined", - "c": "undefined undefined" - }, - "locals": { - "ex1": { - "#__proto__": "Error ", - "message": "string ", - "description": "string ", - "number": "number -2146823279", - "stack": "string " - } - }, - "scopes0": { - "arguments": "Object {...}", - "mm": "Array [22,33]", - "f1": "function function f1() {}", - "a": "number 10", - "b": "Object {...}", - "c1": "Array [1]" - }, - "globals": { - "foo": "function ", - "bar": "function ", - "obj": "undefined undefined", - "c": "undefined undefined" - } - }, - { - "evaluate": { - "ex1": "Error " - } - }, - { - "evaluate": { - "c1": "Array [1]" - } - }, - { - "this": { - "foo": "function ", - "bar": "function ", - "obj": "undefined undefined", - "c": "undefined undefined" - }, "locals": { + "ex1": { + "#__proto__": "Object {...}", + "message": "string ", + "description": "string ", + "number": "number -2146823279", + "stack": "string " + } + }, + "scopes0": { + "arguments": "Object {...}", + "mm": "Array [22,33]", + "f1": "function function f1() {}", + "a": "number 10", + "b": "Object {...}", + "c1": "Array [1]" + }, + "globals": { + "obj": "undefined undefined", + "c": "undefined undefined", + "foo": "function ", + "bar": "function " + } + }, + { + "evaluate": { + "ex1": "Error " + } + }, + { + "evaluate": { + "c1": "Array [1]" + } + }, + { + "this": { + "obj": "undefined undefined", + "c": "undefined undefined", + "foo": "function ", + "bar": "function " + }, + "locals": { + "obj": "undefined undefined", + "c": "undefined undefined", "foo": { "#__proto__": "function ", "prototype": "Object {...}", @@ -112,27 +114,27 @@ "caller": "object null", "arguments": "object null", "length": "number 0" - }, - "obj": "undefined undefined", - "c": "undefined undefined" + } }, "globals": {} }, { "this": { - "foo": "function ", - "bar": "function ", "obj": "undefined undefined", - "c": "undefined undefined" + "c": "undefined undefined", + "foo": "function ", + "bar": "function " }, "locals": { "ex2": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "message": "string ", "description": "string ", "number": "number -2146823279", "stack": "string " }, + "obj": "undefined undefined", + "c": "undefined undefined", "foo": { "#__proto__": "function ", "prototype": "Object {...}", @@ -148,20 +150,24 @@ "caller": "object null", "arguments": "object null", "length": "number 0" - }, - "obj": "undefined undefined", - "c": "undefined undefined" + } }, "globals": {} }, { "this": { - "foo": "function ", - "bar": "function ", "obj": "Object {...}", - "c": "number 10" + "c": "number 10", + "foo": "function ", + "bar": "function " }, "locals": { + "obj": { + "#__proto__": "Object {...}", + "x": "number 10", + "y": "Array [11,22]" + }, + "c": "number 10", "foo": { "#__proto__": "function ", "prototype": "Object {...}", @@ -177,13 +183,7 @@ "caller": "object null", "arguments": "object null", "length": "number 0" - }, - "obj": { - "#__proto__": "Object {...}", - "x": "number 10", - "y": "Array [11,22]" - }, - "c": "number 10" + } }, "globals": {} }, diff --git a/test/DebuggerCommon/indexprop.js.dbg.baseline b/test/DebuggerCommon/indexprop.js.dbg.baseline index c1ad86c45a4..23442f1105d 100644 --- a/test/DebuggerCommon/indexprop.js.dbg.baseline +++ b/test/DebuggerCommon/indexprop.js.dbg.baseline @@ -51,9 +51,7 @@ "toLocaleString": "function ", "toString": "function ", "unshift": "function ", - "indexOf": "function ", "every": "function ", - "filter": "function ", "forEach": "function ", "lastIndexOf": "function ", "map": "function ", @@ -70,6 +68,8 @@ "values": "function ", "Symbol.iterator": "function ", "entries": "function ", + "indexOf": "function ", + "filter": "function ", "length": "number 0" }, "length": "number 8", @@ -95,14 +95,14 @@ "[104]": "string 104" }, "[4]": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "description": "string ErrorObj", "message": "string ErrorObj", "stack": "string ", "[105]": "string 105" }, "[5]": { - "#__proto__": "RegExp ", + "#__proto__": "Object {...}", "lastIndex": "number 0", "global": "boolean false", "multiline": "boolean false", @@ -114,7 +114,7 @@ "[106]": "string 106" }, "[6]": { - "#__proto__": "Date Invalid Date", + "#__proto__": "Object {...}", "[107]": "string 107" }, "[7]": { diff --git a/test/DebuggerCommon/step_out_direct_attach.js.dbg.baseline b/test/DebuggerCommon/step_out_direct_attach.js.dbg.baseline index 6a6559dfbf6..388d8fbe431 100644 --- a/test/DebuggerCommon/step_out_direct_attach.js.dbg.baseline +++ b/test/DebuggerCommon/step_out_direct_attach.js.dbg.baseline @@ -33,7 +33,7 @@ "length": "number 0" }, "c": { - "#__proto__": "Date Invalid Date" + "#__proto__": "Object {...}" } }, "globals": { @@ -118,7 +118,7 @@ "length": "number 0" }, "c": { - "#__proto__": "Date Invalid Date" + "#__proto__": "Object {...}" } }, "globals": { diff --git a/test/DebuggerCommon/step_out_from_JITted_function_attach.js.dbg.baseline b/test/DebuggerCommon/step_out_from_JITted_function_attach.js.dbg.baseline index 1b23d1329bb..24b6a8c8768 100644 --- a/test/DebuggerCommon/step_out_from_JITted_function_attach.js.dbg.baseline +++ b/test/DebuggerCommon/step_out_from_JITted_function_attach.js.dbg.baseline @@ -40,7 +40,7 @@ "length": "number 0" }, "c": { - "#__proto__": "Date Invalid Date" + "#__proto__": "Object {...}" } }, "globals": { diff --git a/test/DebuggerCommon/step_out_from_catch_attach.js.dbg.baseline b/test/DebuggerCommon/step_out_from_catch_attach.js.dbg.baseline index 9862be5ebe2..03a1b20297c 100644 --- a/test/DebuggerCommon/step_out_from_catch_attach.js.dbg.baseline +++ b/test/DebuggerCommon/step_out_from_catch_attach.js.dbg.baseline @@ -14,7 +14,7 @@ "locals": { "x": "number 1", "e": { - "#__proto__": "Error ", + "#__proto__": "Object {...}", "number": "number 0", "description": "string ", "stack": "string " diff --git a/test/Lib/error.baseline b/test/Lib/error.baseline index 1fe92a5d80c..fe75c80bca5 100644 --- a/test/Lib/error.baseline +++ b/test/Lib/error.baseline @@ -1 +1 @@ -false +true diff --git a/test/Lib/getclass1.baseline b/test/Lib/getclass1.baseline index 9d064309eab..c5d1252cfb2 100644 --- a/test/Lib/getclass1.baseline +++ b/test/Lib/getclass1.baseline @@ -3,12 +3,12 @@ Array.prototype.getClass() : [object Array] b1.getClass() : [object Boolean] Boolean.prototype.getClass() : [object Boolean] d1.getClass() : [object Date] -Date.prototype.getClass() : [object Date] +Date.prototype.getClass() : [object Object] f1.getClass() : [object Function] Function.prototype.getClass(): [object Function] n1.getClass() : [object Number] Number.prototype.getClass() : [object Number] r1.getClass() : [object RegExp] -RegExp.prototype.getClass() : [object RegExp] +RegExp.prototype.getClass() : [object Object] s1.getClass() : [object String] String.prototype.getClass() : [object String] diff --git a/test/Prototypes/initProto.baseline b/test/Prototypes/initProto.baseline index 221ebca3b7d..b6d24b68105 100644 --- a/test/Prototypes/initProto.baseline +++ b/test/Prototypes/initProto.baseline @@ -8,21 +8,21 @@ typeof(Boolean.prototype) = object Boolean.prototype.length = undefined typeof(Boolean.prototype.length) = undefined Boolean.prototype.toString() = false -Date.prototype = Invalid Date +Date.prototype = err: TypeError: Date.prototype.toString: 'this' is not a Date object typeof(Date.prototype) = object Date.prototype.length = undefined typeof(Date.prototype.length) = undefined -Date.prototype.toString() = Invalid Date +Date.prototype.toString() = err: TypeError: Date.prototype.toString: 'this' is not a Date object Number.prototype = 0 typeof(Number.prototype) = object Number.prototype.length = undefined typeof(Number.prototype.length) = undefined Number.prototype.toString() = 0 -RegExp.prototype = /(?:)/ +RegExp.prototype = err: TypeError: RegExp.prototype.toString: 'this' is not a RegExp object typeof(RegExp.prototype) = object RegExp.prototype.length = undefined typeof(RegExp.prototype.length) = undefined -RegExp.prototype.toString() = /(?:)/ +RegExp.prototype.toString() = err: TypeError: RegExp.prototype.toString: 'this' is not a RegExp object String.prototype = typeof(String.prototype) = object String.prototype.length = 0 diff --git a/test/Prototypes/initProto.js b/test/Prototypes/initProto.js index edf8300159c..d1fe62991e6 100644 --- a/test/Prototypes/initProto.js +++ b/test/Prototypes/initProto.js @@ -7,7 +7,11 @@ function write(v) { WScript.Echo(v + ""); } function doEval(str) { - write(str + " = " + eval(str)); + try { + write(str + " = " + eval(str)); + } catch (e) { + write(str + " = err: " + e); + } } function check(type) diff --git a/test/StackTrace/ErrorPrototype.baseline b/test/StackTrace/ErrorPrototype.baseline index 23b65605734..8e77a64c410 100644 --- a/test/StackTrace/ErrorPrototype.baseline +++ b/test/StackTrace/ErrorPrototype.baseline @@ -1,66 +1,46 @@ Prototype is new Error() Error: Prototype is new Error() - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:41:5) - at runtest (ErrorPrototype.js:46:5) - at Global code (ErrorPrototype.js:62:1) + at testErrorStack (ErrorPrototype.js:21:9) + at testErrorPrototype (ErrorPrototype.js:34:5) + at testErrorPrototypeChain (ErrorPrototype.js:41:5) + at runtest (ErrorPrototype.js:46:5) + at Global code (ErrorPrototype.js:62:1) Prototype has new Error() Error: Prototype has new Error() - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:42:5) - at runtest (ErrorPrototype.js:46:5) - at Global code (ErrorPrototype.js:62:1) + at testErrorStack (ErrorPrototype.js:21:9) + at testErrorPrototype (ErrorPrototype.js:34:5) + at testErrorPrototypeChain (ErrorPrototype.js:42:5) + at runtest (ErrorPrototype.js:46:5) + at Global code (ErrorPrototype.js:62:1) Prototype is Error.prototype -Error: Prototype is Error.prototype - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:41:5) - at runtest (ErrorPrototype.js:47:5) - at Global code (ErrorPrototype.js:62:1) +undefined Prototype has Error.prototype -Error: Prototype has Error.prototype - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:42:5) - at runtest (ErrorPrototype.js:47:5) - at Global code (ErrorPrototype.js:62:1) +undefined Prototype is new RangeError() RangeError: Prototype is new RangeError() - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:41:5) - at runtest (ErrorPrototype.js:48:5) - at Global code (ErrorPrototype.js:62:1) + at testErrorStack (ErrorPrototype.js:21:9) + at testErrorPrototype (ErrorPrototype.js:34:5) + at testErrorPrototypeChain (ErrorPrototype.js:41:5) + at runtest (ErrorPrototype.js:48:5) + at Global code (ErrorPrototype.js:62:1) Prototype has new RangeError() RangeError: Prototype has new RangeError() - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:42:5) - at runtest (ErrorPrototype.js:48:5) - at Global code (ErrorPrototype.js:62:1) + at testErrorStack (ErrorPrototype.js:21:9) + at testErrorPrototype (ErrorPrototype.js:34:5) + at testErrorPrototypeChain (ErrorPrototype.js:42:5) + at runtest (ErrorPrototype.js:48:5) + at Global code (ErrorPrototype.js:62:1) Prototype is RangeError.prototype -RangeError: Prototype is RangeError.prototype - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:41:5) - at runtest (ErrorPrototype.js:49:5) - at Global code (ErrorPrototype.js:62:1) +undefined Prototype has RangeError.prototype -RangeError: Prototype has RangeError.prototype - at testErrorStack (ErrorPrototype.js:21:9) - at testErrorPrototype (ErrorPrototype.js:34:5) - at testErrorPrototypeChain (ErrorPrototype.js:42:5) - at runtest (ErrorPrototype.js:49:5) - at Global code (ErrorPrototype.js:62:1) +undefined Prototype is 123 undefined diff --git a/test/StackTrace/ErrorPrototype.js b/test/StackTrace/ErrorPrototype.js index 8941a55f687..71b9b940f50 100644 --- a/test/StackTrace/ErrorPrototype.js +++ b/test/StackTrace/ErrorPrototype.js @@ -11,7 +11,7 @@ function Dump(output) { if (this.WScript) { WScript.Echo(output); } else { - alert(output); + console.log(output);//alert(output); } } @@ -20,7 +20,7 @@ function testErrorStack(throwObject, msg) { try { throw throwObject; } catch (e) { - Dump(TrimStackTracePath(e.stack)); + Dump((e.stack)); } Dump(""); } diff --git a/test/es6/regexflags.js b/test/es6/regexflags.js index dd6dcb07ad5..e2d3673ed50 100644 --- a/test/es6/regexflags.js +++ b/test/es6/regexflags.js @@ -59,8 +59,8 @@ var tests = [ { name: "Test sticky and unicode getter on RegExp.prototype", body: function () { - assert.isFalse(RegExp.prototype.unicode, "RegExp.prototype.unicode"); - assert.isFalse(RegExp.prototype.sticky, "RegExp.prototype.sticky"); + assert.isUndefined(RegExp.prototype.unicode, "RegExp.prototype.unicode"); + assert.isUndefined(RegExp.prototype.sticky, "RegExp.prototype.sticky"); function verifier(r, expectedUnicode, expectedSticky) {