X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/blobdiff_plain/4be4e30906bcb8ee30b4d189205cb70bad6707ce..81345200c95645a1b0d2635520f96ad55dfde63f:/tests/stress/runtime-array.js diff --git a/tests/stress/runtime-array.js b/tests/stress/runtime-array.js new file mode 100644 index 0000000..aee6fd7 --- /dev/null +++ b/tests/stress/runtime-array.js @@ -0,0 +1,13 @@ +function testArrayConcat() { + var array = createRuntimeArray(1, 2, 3); + var result = array.concat(); + + if (result.length != 3) + throw new Error("Runtime array length is incorrect"); + for (var i = 0; i < result.length; i++) { + if (result[i] != i + 1) + throw new Error("Runtime array concat result is incorrect"); + } +}; + +testArrayConcat();