« Bugzilla Issues Index

#93 — test 10.6-13-a-1 depends upon the result of applying toString to a function

This test expects a specific string result for applying toString to a function. As described in bug 92 this is invalid as the result of toString for functions is implementation defined.

Rather than testing the source code of the function the test should do something like:

var expectedFunction=undefined;
var argObj = function f() {expectedFunction=f; return arguments;}();
var verifyValue = argObj.callee === expectedFunction &&
typeof argObj.callee === "function";

Agreed. Will fix the test in Hg shortly.