aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/parserstress/tests/ecma/ObjectObjects
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qml/parserstress/tests/ecma/ObjectObjects')
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.1.js146
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.2.js81
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.1.js138
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.2.js74
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3-1.js64
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-1.js69
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-2.js70
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-3.js70
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-4.js70
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.js67
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.1.js64
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.2.js130
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.3.js117
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/browser.js0
-rw-r--r--tests/auto/qml/parserstress/tests/ecma/ObjectObjects/shell.js1
15 files changed, 1161 insertions, 0 deletions
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.1.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.1.js
new file mode 100644
index 0000000000..73ddd2894c
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.1.js
@@ -0,0 +1,146 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.1.1.js';
+
+/**
+ File Name: 15.2.1.1.js
+ ECMA Section: 15.2.1.1 The Object Constructor Called as a Function:
+ Object(value)
+ Description: When Object is called as a function rather than as a
+ constructor, the following steps are taken:
+
+ 1. If value is null or undefined, create and return a
+ new object with no properties other than internal
+ properties exactly as if the object constructor
+ had been called on that same value (15.2.2.1).
+ 2. Return ToObject (value), whose rules are:
+
+ undefined generate a runtime error
+ null generate a runtime error
+ boolean create a new Boolean object whose default
+ value is the value of the boolean.
+ number Create a new Number object whose default
+ value is the value of the number.
+ string Create a new String object whose default
+ value is the value of the string.
+ object Return the input argument (no conversion).
+
+ Author: christine@netscape.com
+ Date: 17 july 1997
+*/
+
+var SECTION = "15.2.1.1";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object( value )";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+
+var NULL_OBJECT = Object(null);
+
+new TestCase( SECTION, "Object(null).valueOf()", NULL_OBJECT, (NULL_OBJECT).valueOf() );
+new TestCase( SECTION, "typeof Object(null)", "object", typeof (Object(null)) );
+
+var UNDEFINED_OBJECT = Object( void 0 );
+
+new TestCase( SECTION, "Object(void 0).valueOf()", UNDEFINED_OBJECT, (UNDEFINED_OBJECT).valueOf() );
+new TestCase( SECTION, "typeof Object(void 0)", "object", typeof (Object(void 0)) );
+
+new TestCase( SECTION, "Object(true).valueOf()", true, (Object(true)).valueOf() );
+new TestCase( SECTION, "typeof Object(true)", "object", typeof Object(true) );
+new TestCase( SECTION, "var MYOB = Object(true); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Boolean]", eval("var MYOB = Object(true); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(false).valueOf()", false, (Object(false)).valueOf() );
+new TestCase( SECTION, "typeof Object(false)", "object", typeof Object(false) );
+new TestCase( SECTION, "var MYOB = Object(false); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Boolean]", eval("var MYOB = Object(false); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(0).valueOf()", 0, (Object(0)).valueOf() );
+new TestCase( SECTION, "typeof Object(0)", "object", typeof Object(0) );
+new TestCase( SECTION, "var MYOB = Object(0); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(0); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(-0).valueOf()", -0, (Object(-0)).valueOf() );
+new TestCase( SECTION, "typeof Object(-0)", "object", typeof Object(-0) );
+new TestCase( SECTION, "var MYOB = Object(-0); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(-0); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(1).valueOf()", 1, (Object(1)).valueOf() );
+new TestCase( SECTION, "typeof Object(1)", "object", typeof Object(1) );
+new TestCase( SECTION, "var MYOB = Object(1); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(1); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(-1).valueOf()", -1, (Object(-1)).valueOf() );
+new TestCase( SECTION, "typeof Object(-1)", "object", typeof Object(-1) );
+new TestCase( SECTION, "var MYOB = Object(-1); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(-1); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(Number.MAX_VALUE).valueOf()", 1.7976931348623157e308, (Object(Number.MAX_VALUE)).valueOf() );
+new TestCase( SECTION, "typeof Object(Number.MAX_VALUE)", "object", typeof Object(Number.MAX_VALUE) );
+new TestCase( SECTION, "var MYOB = Object(Number.MAX_VALUE); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(Number.MAX_VALUE); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(Number.MIN_VALUE).valueOf()", 5e-324, (Object(Number.MIN_VALUE)).valueOf() );
+new TestCase( SECTION, "typeof Object(Number.MIN_VALUE)", "object", typeof Object(Number.MIN_VALUE) );
+new TestCase( SECTION, "var MYOB = Object(Number.MIN_VALUE); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(Number.MIN_VALUE); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(Number.POSITIVE_INFINITY).valueOf()", Number.POSITIVE_INFINITY, (Object(Number.POSITIVE_INFINITY)).valueOf() );
+new TestCase( SECTION, "typeof Object(Number.POSITIVE_INFINITY)", "object", typeof Object(Number.POSITIVE_INFINITY) );
+new TestCase( SECTION, "var MYOB = Object(Number.POSITIVE_INFINITY); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(Number.POSITIVE_INFINITY); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(Number.NEGATIVE_INFINITY).valueOf()", Number.NEGATIVE_INFINITY, (Object(Number.NEGATIVE_INFINITY)).valueOf() );
+new TestCase( SECTION, "typeof Object(Number.NEGATIVE_INFINITY)", "object", typeof Object(Number.NEGATIVE_INFINITY) );
+new TestCase( SECTION, "var MYOB = Object(Number.NEGATIVE_INFINITY); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(Number.NEGATIVE_INFINITY); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object(Number.NaN).valueOf()", Number.NaN, (Object(Number.NaN)).valueOf() );
+new TestCase( SECTION, "typeof Object(Number.NaN)", "object", typeof Object(Number.NaN) );
+new TestCase( SECTION, "var MYOB = Object(Number.NaN); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("var MYOB = Object(Number.NaN); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object('a string').valueOf()", "a string", (Object("a string")).valueOf() );
+new TestCase( SECTION, "typeof Object('a string')", "object", typeof (Object("a string")) );
+new TestCase( SECTION, "var MYOB = Object('a string'); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object String]", eval("var MYOB = Object('a string'); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object('').valueOf()", "", (Object("")).valueOf() );
+new TestCase( SECTION, "typeof Object('')", "object", typeof (Object("")) );
+new TestCase( SECTION, "var MYOB = Object(''); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object String]", eval("var MYOB = Object(''); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object('\\r\\t\\b\\n\\v\\f').valueOf()", "\r\t\b\n\v\f", (Object("\r\t\b\n\v\f")).valueOf() );
+new TestCase( SECTION, "typeof Object('\\r\\t\\b\\n\\v\\f')", "object", typeof (Object("\\r\\t\\b\\n\\v\\f")) );
+new TestCase( SECTION, "var MYOB = Object('\\r\\t\\b\\n\\v\\f'); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object String]", eval("var MYOB = Object('\\r\\t\\b\\n\\v\\f'); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "Object( '\\\'\\\"\\' ).valueOf()", "\'\"\\", (Object("\'\"\\")).valueOf() );
+new TestCase( SECTION, "typeof Object( '\\\'\\\"\\' )", "object", typeof Object("\'\"\\") );
+// new TestCase( SECTION, "var MYOB = Object( '\\\'\\\"\\' ); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object String]", eval("var MYOB = Object( '\\\'\\\"\\' ); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.2.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.2.js
new file mode 100644
index 0000000000..9e41594430
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.1.2.js
@@ -0,0 +1,81 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.1.2.js';
+
+/**
+ File Name: 15.2.1.2.js
+ ECMA Section: 15.2.1.2 The Object Constructor Called as a Function:
+ Object(value)
+ Description: When Object is called as a function rather than as a
+ constructor, the following steps are taken:
+
+ 1. If value is null or undefined, create and return a
+ new object with no proerties other than internal
+ properties exactly as if the object constructor
+ had been called on that same value (15.2.2.1).
+ 2. Return ToObject (value), whose rules are:
+
+ undefined generate a runtime error
+ null generate a runtime error
+ boolean create a new Boolean object whose default
+ value is the value of the boolean.
+ number Create a new Number object whose default
+ value is the value of the number.
+ string Create a new String object whose default
+ value is the value of the string.
+ object Return the input argument (no conversion).
+
+ Author: christine@netscape.com
+ Date: 17 july 1997
+*/
+
+var SECTION = "15.2.1.2";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object()";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+var MYOB = Object();
+
+new TestCase( SECTION, "var MYOB = Object(); MYOB.valueOf()", MYOB, MYOB.valueOf() );
+new TestCase( SECTION, "typeof Object()", "object", typeof (Object(null)) );
+new TestCase( SECTION, "var MYOB = Object(); MYOB.toString()", "[object Object]", eval("var MYOB = Object(); MYOB.toString()") );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.1.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.1.js
new file mode 100644
index 0000000000..dfdfaeb4ab
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.1.js
@@ -0,0 +1,138 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.2.1.js';
+
+/**
+ File Name: 15.2.2.1.js
+ ECMA Section: 15.2.2.1 The Object Constructor: new Object( value )
+
+ 1.If the type of the value is not Object, go to step 4.
+ 2.If the value is a native ECMAScript object, do not create a new object; simply return value.
+ 3.If the value is a host object, then actions are taken and a result is returned in an
+ implementation-dependent manner that may depend on the host object.
+ 4.If the type of the value is String, return ToObject(value).
+ 5.If the type of the value is Boolean, return ToObject(value).
+ 6.If the type of the value is Number, return ToObject(value).
+ 7.(The type of the value must be Null or Undefined.) Create a new native ECMAScript object.
+ The [[Prototype]] property of the newly constructed object is set to the Object prototype object.
+ The [[Class]] property of the newly constructed object is set to "Object".
+ The newly constructed object has no [[Value]] property.
+ Return the newly created native object.
+
+ Description: This does not test cases where the object is a host object.
+ Author: christine@netscape.com
+ Date: 7 october 1997
+*/
+
+var SECTION = "15.2.2.1";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "new Object( value )";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+
+new TestCase( SECTION, "typeof new Object(null)", "object", typeof new Object(null) );
+new TestCase( SECTION, "MYOB = new Object(null); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Object]", eval("MYOB = new Object(null); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "typeof new Object(void 0)", "object", typeof new Object(void 0) );
+new TestCase( SECTION, "MYOB = new Object(new Object(void 0)); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Object]", eval("MYOB = new Object(new Object(void 0)); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+
+new TestCase( SECTION, "typeof new Object('string')", "object", typeof new Object('string') );
+new TestCase( SECTION, "MYOB = (new Object('string'); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object String]", eval("MYOB = new Object('string'); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object('string').valueOf()", "string", (new Object('string')).valueOf() );
+
+new TestCase( SECTION, "typeof new Object('')", "object", typeof new Object('') );
+new TestCase( SECTION, "MYOB = (new Object(''); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object String]", eval("MYOB = new Object(''); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object('').valueOf()", "", (new Object('')).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(Number.NaN)", "object", typeof new Object(Number.NaN) );
+new TestCase( SECTION, "MYOB = (new Object(Number.NaN); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("MYOB = new Object(Number.NaN); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(Number.NaN).valueOf()", Number.NaN, (new Object(Number.NaN)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(0)", "object", typeof new Object(0) );
+new TestCase( SECTION, "MYOB = (new Object(0); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("MYOB = new Object(0); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(0).valueOf()", 0, (new Object(0)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(-0)", "object", typeof new Object(-0) );
+new TestCase( SECTION, "MYOB = (new Object(-0); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("MYOB = new Object(-0); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(-0).valueOf()", -0, (new Object(-0)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(1)", "object", typeof new Object(1) );
+new TestCase( SECTION, "MYOB = (new Object(1); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("MYOB = new Object(1); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(1).valueOf()", 1, (new Object(1)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(-1)", "object", typeof new Object(-1) );
+new TestCase( SECTION, "MYOB = (new Object(-1); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Number]", eval("MYOB = new Object(-1); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(-1).valueOf()", -1, (new Object(-1)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(true)", "object", typeof new Object(true) );
+new TestCase( SECTION, "MYOB = (new Object(true); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Boolean]", eval("MYOB = new Object(true); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(true).valueOf()", true, (new Object(true)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(false)", "object", typeof new Object(false) );
+new TestCase( SECTION, "MYOB = (new Object(false); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Boolean]", eval("MYOB = new Object(false); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(false).valueOf()", false, (new Object(false)).valueOf() );
+
+new TestCase( SECTION, "typeof new Object(Boolean())", "object", typeof new Object(Boolean()) );
+new TestCase( SECTION, "MYOB = (new Object(Boolean()); MYOB.toString = Object.prototype.toString; MYOB.toString()", "[object Boolean]", eval("MYOB = new Object(Boolean()); MYOB.toString = Object.prototype.toString; MYOB.toString()") );
+new TestCase( SECTION, "(new Object(Boolean()).valueOf()", Boolean(), (new Object(Boolean())).valueOf() );
+
+
+var myglobal = this;
+var myobject = new Object( "my new object" );
+var myarray = new Array();
+var myboolean = new Boolean();
+var mynumber = new Number();
+var mystring = new String();
+var myobject = new Object();
+var myfunction = new Function( "x", "return x");
+var mymath = Math;
+
+new TestCase( SECTION, "myglobal = new Object( this )", myglobal, new Object(this) );
+new TestCase( SECTION, "myobject = new Object('my new object'); new Object(myobject)", myobject, new Object(myobject) );
+new TestCase( SECTION, "myarray = new Array(); new Object(myarray)", myarray, new Object(myarray) );
+new TestCase( SECTION, "myboolean = new Boolean(); new Object(myboolean)", myboolean, new Object(myboolean) );
+new TestCase( SECTION, "mynumber = new Number(); new Object(mynumber)", mynumber, new Object(mynumber) );
+new TestCase( SECTION, "mystring = new String9); new Object(mystring)", mystring, new Object(mystring) );
+new TestCase( SECTION, "myobject = new Object(); new Object(mynobject)", myobject, new Object(myobject) );
+new TestCase( SECTION, "myfunction = new Function(); new Object(myfunction)", myfunction, new Object(myfunction) );
+new TestCase( SECTION, "mymath = Math; new Object(mymath)", mymath, new Object(mymath) );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.2.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.2.js
new file mode 100644
index 0000000000..2a5743a826
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.2.2.js
@@ -0,0 +1,74 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.2.2.js';
+
+/**
+ File Name: 15.2.2.2.js
+ ECMA Section: 15.2.2.2 new Object()
+ Description:
+
+ When the Object constructor is called with no argument, the following
+ step is taken:
+
+ 1. Create a new native ECMAScript object.
+ The [[Prototype]] property of the newly constructed object is set to
+ the Object prototype object.
+
+ The [[Class]] property of the newly constructed object is set
+ to "Object".
+
+ The newly constructed object has no [[Value]] property.
+
+ Return the newly created native object.
+
+ Author: christine@netscape.com
+ Date: 7 october 1997
+*/
+var SECTION = "15.2.2.2";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "new Object()";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION, "typeof new Object()", "object", typeof new Object() );
+new TestCase( SECTION, "Object.prototype.toString()", "[object Object]", Object.prototype.toString() );
+new TestCase( SECTION, "(new Object()).toString()", "[object Object]", (new Object()).toString() );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3-1.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3-1.js
new file mode 100644
index 0000000000..5242d7e6a5
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3-1.js
@@ -0,0 +1,64 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.3-1.js';
+
+/**
+ File Name: 15.2.3-1.js
+ ECMA Section: 15.2.3 Properties of the Object Constructor
+
+ Description: The value of the internal [[Prototype]] property of the
+ Object constructor is the Function prototype object.
+
+ Besides the call and construct propreties and the length
+ property, the Object constructor has properties described
+ in 15.2.3.1.
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+var SECTION = "15.2.3";
+var VERSION = "ECMA_2";
+startTest();
+
+writeHeaderToLog( SECTION + " Properties of the Object Constructor");
+
+new TestCase( SECTION, "Object.length", 1, Object.length );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-1.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-1.js
new file mode 100644
index 0000000000..39510b6b22
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-1.js
@@ -0,0 +1,69 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.3.1-1.js';
+
+/**
+ File Name: 15.2.3.1-1.js
+ ECMA Section: 15.2.3.1 Object.prototype
+
+ Description: The initial value of Object.prototype is the built-in
+ Object prototype object.
+
+ This property shall have the attributes [ DontEnum,
+ DontDelete ReadOnly ]
+
+ This tests the [DontEnum] property of Object.prototype
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+var SECTION = "15.2.3.1-1";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION,
+ "var str = '';for ( p in Object ) { str += p; }; str",
+ "",
+ eval( "var str = ''; for ( p in Object ) { str += p; }; str" ) );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-2.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-2.js
new file mode 100644
index 0000000000..a92739f2d1
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-2.js
@@ -0,0 +1,70 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.3.1-2.js';
+
+/**
+ File Name: 15.2.3.1-2.js
+ ECMA Section: 15.2.3.1 Object.prototype
+
+ Description: The initial value of Object.prototype is the built-in
+ Object prototype object.
+
+ This property shall have the attributes [ DontEnum,
+ DontDelete ReadOnly ]
+
+ This tests the [DontDelete] property of Object.prototype
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+
+var SECTION = "15.2.3.1-2";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION,
+ "delete( Object.prototype )",
+ false,
+ eval("delete( Object.prototype )") );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-3.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-3.js
new file mode 100644
index 0000000000..0a82c6cd02
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-3.js
@@ -0,0 +1,70 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.3.1-3.js';
+
+/**
+ File Name: 15.2.3.1-3.js
+ ECMA Section: 15.2.3.1 Object.prototype
+
+ Description: The initial value of Object.prototype is the built-in
+ Object prototype object.
+
+ This property shall have the attributes [ DontEnum,
+ DontDelete ReadOnly ]
+
+ This tests the [ReadOnly] property of Object.prototype
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+
+var SECTION = "15.2.3.1-3";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION,
+ "Object.prototype = null; Object.prototype",
+ Object.prototype,
+ eval("Object.prototype = null; Object.prototype"));
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-4.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-4.js
new file mode 100644
index 0000000000..86be98e1ad
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.1-4.js
@@ -0,0 +1,70 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.3.1-4.js';
+
+/**
+ File Name: 15.2.3.1-4.js
+ ECMA Section: 15.2.3.1 Object.prototype
+
+ Description: The initial value of Object.prototype is the built-in
+ Object prototype object.
+
+ This property shall have the attributes [ DontEnum,
+ DontDelete ReadOnly ]
+
+ This tests the [DontDelete] property of Object.prototype
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+
+var SECTION = "15.2.3.1-4";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION,
+ "delete( Object.prototype ); Object.prototype",
+ Object.prototype,
+ eval("delete(Object.prototype); Object.prototype") );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.js
new file mode 100644
index 0000000000..70a9605c2e
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.3.js
@@ -0,0 +1,67 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.3.js';
+
+/**
+ File Name: 15.2.3.js
+ ECMA Section: 15.2.3 Properties of the Object Constructor
+
+ Description: The value of the internal [[Prototype]] property of the
+ Object constructor is the Function prototype object.
+
+ Besides the call and construct propreties and the length
+ property, the Object constructor has properties described
+ in 15.2.3.1.
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+
+var SECTION = "15.2.3";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Properties of the Object Constructor";
+
+writeHeaderToLog( SECTION + " " + TITLE);
+
+// new TestCase( SECTION, "Object.__proto__", Function.prototype, Object.__proto__ );
+new TestCase( SECTION, "Object.length", 1, Object.length );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.1.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.1.js
new file mode 100644
index 0000000000..bff668f43c
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.1.js
@@ -0,0 +1,64 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.4.1.js';
+
+/**
+ File Name: 15.2.4.1.js
+ ECMA Section: 15.2.4 Object.prototype.constructor
+
+ Description: The initial value of the Object.prototype.constructor
+ is the built-in Object constructor.
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+var SECTION = "15.2.4.1";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype.constructor";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION,
+ "Object.prototype.constructor",
+ Object,
+ Object.prototype.constructor );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.2.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.2.js
new file mode 100644
index 0000000000..c52a825bb8
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.2.js
@@ -0,0 +1,130 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.4.2.js';
+
+/**
+ File Name: 15.2.4.2.js
+ ECMA Section: 15.2.4.2 Object.prototype.toString()
+
+ Description: When the toString method is called, the following
+ steps are taken:
+ 1. Get the [[Class]] property of this object
+ 2. Call ToString( Result(1) )
+ 3. Compute a string value by concatenating the three
+ strings "[object " + Result(2) + "]"
+ 4. Return Result(3).
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+var SECTION = "15.2.4.2";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype.toString()";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+new TestCase( SECTION, "(new Object()).toString()", "[object Object]", (new Object()).toString() );
+
+new TestCase( SECTION, "myvar = this; myvar.toString = Object.prototype.toString; myvar.toString()",
+ GLOBAL.replace(/ @ 0x[0-9a-fA-F]+ \(native @ 0x[0-9a-fA-F]+\)/, ''),
+ eval("myvar = this; myvar.toString = Object.prototype.toString; myvar.toString()")
+ );
+
+new TestCase( SECTION, "myvar = MyObject; myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Function]",
+ eval("myvar = MyObject; myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new MyObject( true ); myvar.toString = Object.prototype.toString; myvar.toString()",
+ '[object Object]',
+ eval("myvar = new MyObject( true ); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new Number(0); myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Number]",
+ eval("myvar = new Number(0); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new String(''); myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object String]",
+ eval("myvar = new String(''); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = Math; myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Math]",
+ eval("myvar = Math; myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new Function(); myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Function]",
+ eval("myvar = new Function(); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new Array(); myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Array]",
+ eval("myvar = new Array(); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new Boolean(); myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Boolean]",
+ eval("myvar = new Boolean(); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "myvar = new Date(); myvar.toString = Object.prototype.toString; myvar.toString()",
+ "[object Date]",
+ eval("myvar = new Date(); myvar.toString = Object.prototype.toString; myvar.toString()") );
+
+new TestCase( SECTION, "var MYVAR = new Object( this ); MYVAR.toString()",
+ GLOBAL.replace(/ @ 0x[0-9a-fA-F]+ \(native @ 0x[0-9a-fA-F]+\)/, ''),
+ eval("var MYVAR = new Object( this ); MYVAR.toString()")
+ );
+
+new TestCase( SECTION, "var MYVAR = new Object(); MYVAR.toString()",
+ "[object Object]",
+ eval("var MYVAR = new Object(); MYVAR.toString()") );
+
+new TestCase( SECTION, "var MYVAR = new Object(void 0); MYVAR.toString()",
+ "[object Object]",
+ eval("var MYVAR = new Object(void 0); MYVAR.toString()") );
+
+new TestCase( SECTION, "var MYVAR = new Object(null); MYVAR.toString()",
+ "[object Object]",
+ eval("var MYVAR = new Object(null); MYVAR.toString()") );
+
+
+function MyObject( value ) {
+ this.value = new Function( "return this.value" );
+ this.toString = new Function ( "return this.value+''");
+}
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.3.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.3.js
new file mode 100644
index 0000000000..17c4558679
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/15.2.4.3.js
@@ -0,0 +1,117 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Mozilla Communicator client code, released
+ * March 31, 1998.
+ *
+ * The Initial Developer of the Original Code is
+ * Netscape Communications Corporation.
+ * Portions created by the Initial Developer are Copyright (C) 1998
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+gTestfile = '15.2.4.3.js';
+
+/**
+ File Name: 15.2.4.3.js
+ ECMA Section: 15.2.4.3 Object.prototype.valueOf()
+
+ Description: As a rule, the valueOf method for an object simply
+ returns the object; but if the object is a "wrapper"
+ for a host object, as may perhaps be created by the
+ Object constructor, then the contained host object
+ should be returned.
+
+ This only covers native objects.
+
+ Author: christine@netscape.com
+ Date: 28 october 1997
+
+*/
+var SECTION = "15.2.4.3";
+var VERSION = "ECMA_1";
+startTest();
+var TITLE = "Object.prototype.valueOf()";
+
+writeHeaderToLog( SECTION + " "+ TITLE);
+
+
+var myarray = new Array();
+myarray.valueOf = Object.prototype.valueOf;
+var myboolean = new Boolean();
+myboolean.valueOf = Object.prototype.valueOf;
+var myfunction = new Function();
+myfunction.valueOf = Object.prototype.valueOf;
+var myobject = new Object();
+myobject.valueOf = Object.prototype.valueOf;
+var mymath = Math;
+mymath.valueOf = Object.prototype.valueOf;
+var mydate = new Date();
+mydate.valueOf = Object.prototype.valueOf;
+var mynumber = new Number();
+mynumber.valueOf = Object.prototype.valueOf;
+var mystring = new String();
+mystring.valueOf = Object.prototype.valueOf;
+
+new TestCase( SECTION, "Object.prototype.valueOf.length", 0, Object.prototype.valueOf.length );
+
+new TestCase( SECTION,
+ "myarray = new Array(); myarray.valueOf = Object.prototype.valueOf; myarray.valueOf()",
+ myarray,
+ myarray.valueOf() );
+new TestCase( SECTION,
+ "myboolean = new Boolean(); myboolean.valueOf = Object.prototype.valueOf; myboolean.valueOf()",
+ myboolean,
+ myboolean.valueOf() );
+new TestCase( SECTION,
+ "myfunction = new Function(); myfunction.valueOf = Object.prototype.valueOf; myfunction.valueOf()",
+ myfunction,
+ myfunction.valueOf() );
+new TestCase( SECTION,
+ "myobject = new Object(); myobject.valueOf = Object.prototype.valueOf; myobject.valueOf()",
+ myobject,
+ myobject.valueOf() );
+new TestCase( SECTION,
+ "mymath = Math; mymath.valueOf = Object.prototype.valueOf; mymath.valueOf()",
+ mymath,
+ mymath.valueOf() );
+new TestCase( SECTION,
+ "mynumber = new Number(); mynumber.valueOf = Object.prototype.valueOf; mynumber.valueOf()",
+ mynumber,
+ mynumber.valueOf() );
+new TestCase( SECTION,
+ "mystring = new String(); mystring.valueOf = Object.prototype.valueOf; mystring.valueOf()",
+ mystring,
+ mystring.valueOf() );
+new TestCase( SECTION,
+ "mydate = new Date(); mydate.valueOf = Object.prototype.valueOf; mydate.valueOf()",
+ mydate,
+ mydate.valueOf() );
+
+test();
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/browser.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/browser.js
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/browser.js
diff --git a/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/shell.js b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/shell.js
new file mode 100644
index 0000000000..1a71207967
--- /dev/null
+++ b/tests/auto/qml/parserstress/tests/ecma/ObjectObjects/shell.js
@@ -0,0 +1 @@
+gTestsubsuite = 'ObjectObjects';