| OLD | NEW |
| (Empty) | |
| 1 This tests that we can correctly call Function.prototype.apply |
| 2 |
| 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
| 4 |
| 5 |
| 6 PASS myObject.apply() is [myObject, "myObject.apply"] |
| 7 PASS forwarder(myObject) is [myObject, "myObject.apply"] |
| 8 PASS myFunction('arg1') is [this, "myFunction", "arg1"] |
| 9 PASS forwarder(myFunction, null, ['arg1']) is [this, "myFunction", "arg1"] |
| 10 PASS myFunction.apply(myObject, ['arg1']) is [myObject, "myFunction", "arg1"] |
| 11 PASS myFunction.apply(myObject, arg1Array) is [myObject, "myFunction", "arg1"] |
| 12 PASS forwarder(myFunction, myObject, arg1Array) is [myObject, "myFunction", "arg
1"] |
| 13 PASS myFunction.apply() is [this, "myFunction", undefined] |
| 14 PASS myFunction.apply(null) is [this, "myFunction", undefined] |
| 15 PASS myFunction.apply(undefined) is [this, "myFunction", undefined] |
| 16 PASS myFunction.aliasedApply(myObject, ['arg1']) is [myObject, "myFunction", "ar
g1"] |
| 17 PASS myFunction.aliasedApply() is [this, "myFunction", undefined] |
| 18 PASS myFunction.aliasedApply(null) is [this, "myFunction", undefined] |
| 19 PASS myFunction.aliasedApply(undefined) is [this, "myFunction", undefined] |
| 20 PASS myFunctionWithApply.apply(myObject, ['arg1']) is [myFunctionWithApply, "myF
unctionWithApply.apply", myObject] |
| 21 PASS myFunctionWithApply.aliasedApply(myObject, ['arg1']) is [myObject, "myFunct
ionWithApply", "arg1"] |
| 22 PASS myFunctionWithApply.apply(myObject, arg1Array) is [myFunctionWithApply, "my
FunctionWithApply.apply", myObject] |
| 23 PASS forwarder(myFunctionWithApply, myObject, arg1Array) is [myFunctionWithApply
, "myFunctionWithApply.apply", myObject] |
| 24 PASS myFunctionWithApply.aliasedApply(myObject, arg1Array) is [myObject, "myFunc
tionWithApply", "arg1"] |
| 25 PASS myFunction.apply(null, new Array(5000000)) threw exception RangeError: Func
tion.prototype.apply cannot support 5000000 arguments. |
| 26 PASS myFunction.apply(null, new Array(1 << 30)) threw exception RangeError: Func
tion.prototype.apply cannot support 1073741824 arguments. |
| 27 PASS recurseArguments.apply(null, new Array(50000)) threw exception RangeError:
Function.prototype.apply cannot support 50000 arguments. |
| 28 PASS successfullyParsed is true |
| 29 |
| 30 TEST COMPLETE |
| 31 |
| OLD | NEW |