Fix bug 411539 Generalize some tests for Rhino and Spidermonkey.

r=bclary@bclary.com
This commit is contained in:
nboyd%atg.com 2008-01-11 17:38:09 +00:00
Родитель 4a8f2feeb9
Коммит 7837d9b0d3
5 изменённых файлов: 13 добавлений и 13 удалений

Просмотреть файл

@ -53,7 +53,7 @@ function test()
printBugNumber(BUGNUMBER); printBugNumber(BUGNUMBER);
printStatus (summary); printStatus (summary);
expect = 'TypeError: NaN is not a function'; expect = /TypeError: NaN is not a function/;
actual = 'No Error'; actual = 'No Error';
try try
{ {
@ -64,7 +64,7 @@ function test()
actual = ex + ''; actual = ex + '';
} }
reportCompare(expect, actual, summary); reportMatch(expect, actual, summary);
exitFunc ('test'); exitFunc ('test');
} }

Просмотреть файл

@ -52,8 +52,8 @@ function test()
enterFunc ('test'); enterFunc ('test');
printBugNumber(BUGNUMBER); printBugNumber(BUGNUMBER);
printStatus (summary); printStatus (summary);
expect = 'TypeError: NaN is not a function'; expect = /TypeError: NaN is not a function/;
actual = 'No Error'; actual = 'No Error';
try try
{ {
@ -64,7 +64,7 @@ function test()
actual = ex + ''; actual = ex + '';
} }
reportCompare(expect, actual, summary); reportMatch(expect, actual, summary);
exitFunc ('test'); exitFunc ('test');
} }

Просмотреть файл

@ -52,8 +52,8 @@ function test()
enterFunc ('test'); enterFunc ('test');
printBugNumber(BUGNUMBER); printBugNumber(BUGNUMBER);
printStatus (summary); printStatus (summary);
expect = 'TypeError: NaN is not a function'; expect = /TypeError: NaN is not a function/;
actual = 'No Error'; actual = 'No Error';
try try
{ {
@ -70,7 +70,7 @@ function test()
actual = ex + ''; actual = ex + '';
} }
reportCompare(expect, actual, summary); reportMatch(expect, actual, summary);
exitFunc ('test'); exitFunc ('test');
} }

Просмотреть файл

@ -40,7 +40,7 @@ var gTestfile = 'regress-352797-02.js';
var BUGNUMBER = 352797; var BUGNUMBER = 352797;
var summary = 'Do not assert: OBJ_GET_CLASS(cx, obj) == &js_BlockClass'; var summary = 'Do not assert: OBJ_GET_CLASS(cx, obj) == &js_BlockClass';
var actual = 'No Crash'; var actual = 'No Crash';
var expect = 'No Crash'; var expect = /No Crash/;
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
@ -60,11 +60,11 @@ function test()
catch(ex) catch(ex)
{ {
printStatus('Note eval can no longer be called directly'); printStatus('Note eval can no longer be called directly');
expect = 'EvalError: function eval must be called directly, and not by way of a function of another name'; expect = /EvalError: (f|F)unction (eval|"eval") must be called directly, and not by way of a function of another name/;
actual = ex + ''; actual = ex + '';
} }
reportCompare(expect, actual, summary); reportMatch(expect, actual, summary);
exitFunc ('test'); exitFunc ('test');
} }

Просмотреть файл

@ -53,7 +53,7 @@ function test()
printBugNumber(BUGNUMBER); printBugNumber(BUGNUMBER);
printStatus (summary); printStatus (summary);
expect = 'ReferenceError: k is not defined'; expect = /ReferenceError: (k|"k") is not defined/;
actual = ''; actual = '';
try try
{ {
@ -65,7 +65,7 @@ function test()
{ {
actual = ex + ''; actual = ex + '';
} }
reportCompare(expect, actual, summary); reportMatch(expect, actual, summary);
exitFunc ('test'); exitFunc ('test');
} }