summaryrefslogtreecommitdiff
path: root/external/contributions/Google/sputnik_conformance_modified/10_Execution_Contexts/10.6_Arguments_Object/S10.1.8_A3_T4.js
diff options
context:
space:
mode:
Diffstat (limited to 'external/contributions/Google/sputnik_conformance_modified/10_Execution_Contexts/10.6_Arguments_Object/S10.1.8_A3_T4.js')
-rw-r--r--external/contributions/Google/sputnik_conformance_modified/10_Execution_Contexts/10.6_Arguments_Object/S10.1.8_A3_T4.js41
1 files changed, 41 insertions, 0 deletions
diff --git a/external/contributions/Google/sputnik_conformance_modified/10_Execution_Contexts/10.6_Arguments_Object/S10.1.8_A3_T4.js b/external/contributions/Google/sputnik_conformance_modified/10_Execution_Contexts/10.6_Arguments_Object/S10.1.8_A3_T4.js
new file mode 100644
index 000000000..fb51ddc8a
--- /dev/null
+++ b/external/contributions/Google/sputnik_conformance_modified/10_Execution_Contexts/10.6_Arguments_Object/S10.1.8_A3_T4.js
@@ -0,0 +1,41 @@
+// Copyright 2009 the Sputnik authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+
+/**
+ * @name: S10.1.8_A3_T4;
+ * @section: 10.1.8;
+ * @assertion: A property is created with name callee with property
+ * attributes { DontEnum } and no others;
+ * @description: Overriding arguments.callee property;
+ * @non_strict_only
+*/
+
+var str = "something different";
+//CHECK#1
+function f1(){
+ arguments.callee = str;
+ return arguments;
+}
+
+try{
+ if(f1().callee !== str){
+ $ERROR("#1: A property callee have attribute { ReadOnly }");
+ }
+}
+catch(e){
+ $ERROR("#1: arguments object don't exists");
+}
+
+//CHECK#2
+var f2 = function(){
+ arguments.callee = str;
+ return arguments;
+ }
+try{
+ if(f2().callee !== str){
+ $ERROR("#2: A property callee have attribute { ReadOnly }");
+ }
+}
+catch(e){
+ $ERROR("#2: arguments object don't exists");
+}