JavaScript Tests - update regression test for bug 274152 due to bug 368516, not part of the build
authorbclary@bclary.com
Thu, 06 Dec 2007 11:23:03 -0800
changeset 8795 ad0151c64ee052b3c40ed2477e60c25828608154
parent 8794 60903a5c45c4ff470d2442fdcc08d40719e3011b
child 8796 b5f5d951791d0d385f8cb9e8013d1e4ac87971f1
push idunknown
push userunknown
push dateunknown
bugs274152, 368516
milestone1.9b2pre
JavaScript Tests - update regression test for bug 274152 due to bug 368516, not part of the build
js/tests/ecma_3/extensions/regress-274152.js
--- a/js/tests/ecma_3/extensions/regress-274152.js
+++ b/js/tests/ecma_3/extensions/regress-274152.js
@@ -49,21 +49,35 @@ test();
 
 function test()
 {
   enterFunc ('test');
   printBugNumber(BUGNUMBER);
   printStatus (summary);
  
   expect = 'SyntaxError: illegal character';
-  try
+
+  var formatcontrolchars = ['\u200C',
+                            '\u200D',
+                            '\u200E', 
+                            '\u0600', 
+                            '\u0601', 
+                            '\u0602', 
+                            '\u0603', 
+                            '\u06DD', 
+                            '\u070F'];
+
+  for (var i = 0; i < formatcontrolchars.length; i++)
   {
-    eval("hi\uFEFFthere = 'howdie';");
+    try
+    {
+      eval("hi" + formatcontrolchars[i] + "there = 'howdie';");
+    }
+    catch(ex)
+    {
+      actual = ex + '';
+    }
+
+    reportCompare(expect, actual, summary + ': ' + i);
   }
-  catch(ex)
-  {
-    actual = ex + '';
-  }
-
-  reportCompare(expect, actual, summary);
 
   exitFunc ('test');
 }