summaryrefslogtreecommitdiff
path: root/external/contributions/Google/sputnik_conformance_modified/15_Native/15.5_String_Objects/15.5.4_Properties_of_the_String_Prototype_Object/15.5.4.14_String.prototype.split/S15.5.4.14_A8.js
diff options
context:
space:
mode:
Diffstat (limited to 'external/contributions/Google/sputnik_conformance_modified/15_Native/15.5_String_Objects/15.5.4_Properties_of_the_String_Prototype_Object/15.5.4.14_String.prototype.split/S15.5.4.14_A8.js')
-rw-r--r--external/contributions/Google/sputnik_conformance_modified/15_Native/15.5_String_Objects/15.5.4_Properties_of_the_String_Prototype_Object/15.5.4.14_String.prototype.split/S15.5.4.14_A8.js40
1 files changed, 40 insertions, 0 deletions
diff --git a/external/contributions/Google/sputnik_conformance_modified/15_Native/15.5_String_Objects/15.5.4_Properties_of_the_String_Prototype_Object/15.5.4.14_String.prototype.split/S15.5.4.14_A8.js b/external/contributions/Google/sputnik_conformance_modified/15_Native/15.5_String_Objects/15.5.4_Properties_of_the_String_Prototype_Object/15.5.4.14_String.prototype.split/S15.5.4.14_A8.js
new file mode 100644
index 000000000..a9e4e8653
--- /dev/null
+++ b/external/contributions/Google/sputnik_conformance_modified/15_Native/15.5_String_Objects/15.5.4_Properties_of_the_String_Prototype_Object/15.5.4.14_String.prototype.split/S15.5.4.14_A8.js
@@ -0,0 +1,40 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+* @name: S15.5.4.14_A8;
+* @section: 15.5.4.14;
+* @assertion: The String.prototype.split.length property has the attribute DontEnum;
+* @description: Checking if enumerating the String.prototype.split.length property fails;
+*/
+
+//////////////////////////////////////////////////////////////////////////////
+//CHECK#0
+if (!(String.prototype.split.hasOwnProperty('length'))) {
+ $FAIL('#0: String.prototype.split.hasOwnProperty(\'length\') return true. Actual: '+String.prototype.split.hasOwnProperty('length'));
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+
+//////////////////////////////////////////////////////////////////////////////
+// CHECK#1
+if (String.prototype.split.propertyIsEnumerable('length')) {
+ $ERROR('#1: String.prototype.split.propertyIsEnumerable(\'length\') return false');
+}
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//////////////////////////////////////////////////////////////////////////////
+// CHECK#2
+var count=0;
+
+for (p in String.prototype.split){
+ if (p==="length") count++;
+}
+
+if (count !== 0) {
+ $ERROR('#2: count=0; for (p in String.prototype.split){if (p==="length") count++;}; count === 0. Actual: '+count );
+}
+//
+//////////////////////////////////////////////////////////////////////////////