diff options
Diffstat (limited to 'test/built-ins/String/prototype/replace/S15.5.4.11_A1_T10.js')
-rw-r--r-- | test/built-ins/String/prototype/replace/S15.5.4.11_A1_T10.js | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/test/built-ins/String/prototype/replace/S15.5.4.11_A1_T10.js b/test/built-ins/String/prototype/replace/S15.5.4.11_A1_T10.js index 552c478ff..c044c8515 100644 --- a/test/built-ins/String/prototype/replace/S15.5.4.11_A1_T10.js +++ b/test/built-ins/String/prototype/replace/S15.5.4.11_A1_T10.js @@ -10,15 +10,23 @@ description: > function ---*/ -var __obj = {toString:function(){return "\u0041B";}}; +var __obj = { + toString: function() { + return "\u0041B"; + } +}; var __str = "ABB\u0041BABAB"; ////////////////////////////////////////////////////////////////////////////// //CHECK#1 - if (__str.replace(__obj, function(){return x;}) !== "undefinedBABABAB") { - $ERROR('#1: var x; var __obj = {toString:function(){return "\u0041B";}}; var __str = "ABB\u0041BABAB"; replace(__obj, function(){return x;}) === "undefinedBABABAB". Actual: '+__str.replace(__obj, function(){return x;}) ); - } +if (__str.replace(__obj, function() { + return x; + }) !== "undefinedBABABAB") { + $ERROR('#1: var x; var __obj = {toString:function(){return "\u0041B";}}; var __str = "ABB\u0041BABAB"; replace(__obj, function(){return x;}) === "undefinedBABABAB". Actual: ' + __str.replace(__obj, function() { + return x; + })); +} // ////////////////////////////////////////////////////////////////////////////// |