Bug 937793 - Various new Array tests. r=bhackett
authorJeff Walden <jwalden@mit.edu>
Wed, 18 Dec 2013 20:14:16 -0500
changeset 172980 9462764e880601ad89e8855e2194cb178cdb1c0e
parent 172979 f98f596ad05604ccbd44b26446cfec01b9b99078
child 172981 b79d5726ac06cef1508ac652e8bc58475cfb0840
push id40902
push userjwalden@mit.edu
push dateTue, 11 Mar 2014 16:40:25 +0000
treeherdermozilla-inbound@b79d5726ac06 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbhackett
bugs937793
milestone30.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 937793 - Various new Array tests. r=bhackett
js/src/jit-test/tests/arrays/new-array-int-undefined-args.js
js/src/jit-test/tests/arrays/new-array-undefined-undefined-more-args-1.js
js/src/jit-test/tests/arrays/new-array-undefined-undefined-more-args-2.js
new file mode 100644
--- /dev/null
+++ b/js/src/jit-test/tests/arrays/new-array-int-undefined-args.js
@@ -0,0 +1,2 @@
+for (var i = 0; i < 1e4; i++)
+  assertEq(new Array(0, undefined).length, 2, "bad, i: " + i);
new file mode 100644
--- /dev/null
+++ b/js/src/jit-test/tests/arrays/new-array-undefined-undefined-more-args-1.js
@@ -0,0 +1,6 @@
+for (var i = 0; i < 1e4; i++)
+{
+  assertEq(typeof new Array(undefined, undefined, 1, 2, 3, 4).sort()[0],
+           "number",
+           "bad, i: " + i);
+}
new file mode 100644
--- /dev/null
+++ b/js/src/jit-test/tests/arrays/new-array-undefined-undefined-more-args-2.js
@@ -0,0 +1,6 @@
+for (var i = 0; i < 1e4; i++)
+{
+  assertEq(new Array(undefined, undefined, 1, 2, 3, 4).length,
+           6,
+           "bad, i: " + i);
+}