summaryrefslogtreecommitdiff
path: root/js/src/tests
diff options
context:
space:
mode:
authorGaming4JC <g4jc@hyperbola.info>2019-07-07 20:36:27 -0400
committerGaming4JC <g4jc@hyperbola.info>2019-07-18 22:38:37 -0400
commit50de15c3a64577f1523ec456df028dc20f539beb (patch)
tree2d6c6aa269e673386cec47191a508d837c29775c /js/src/tests
parentc1ba97eeae3171fb96283583c33f0238cedacab6 (diff)
downloaduxp-50de15c3a64577f1523ec456df028dc20f539beb.tar.gz
1317387: The intrinsic %ThrowTypeError% function should be frozen.
Diffstat (limited to 'js/src/tests')
-rw-r--r--js/src/tests/ecma_6/Function/throw-type-error.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/js/src/tests/ecma_6/Function/throw-type-error.js b/js/src/tests/ecma_6/Function/throw-type-error.js
new file mode 100644
index 0000000000..68dd6e1d07
--- /dev/null
+++ b/js/src/tests/ecma_6/Function/throw-type-error.js
@@ -0,0 +1,16 @@
+// Any copyright is dedicated to the Public Domain.
+// http://creativecommons.org/publicdomain/zero/1.0/
+
+const ThrowTypeError = function(){
+ "use strict";
+ return Object.getOwnPropertyDescriptor(arguments, "callee").get;
+}();
+
+assertDeepEq(Object.getOwnPropertyDescriptor(ThrowTypeError, "length"), {
+ value: 0, writable: false, enumerable: false, configurable: false
+});
+
+assertEq(Object.isFrozen(ThrowTypeError), true);
+
+if (typeof reportCompare == "function")
+ reportCompare(true, true);