Revision: 5362
Author:   [email protected]
Date:     Thu Apr 18 11:36:23 2013
Log:      Remove obsolete 'crossFrameFreezeBug' kludge in tests.
https://codereview.appspot.com/8856043

Separately testing for the bug is no longer necessary as the information
is available via cajaVM.es5ProblemReports.FREEZE_IS_FRAME_DEPENDENT, and
testing for the bug at all is no longer necessary since we have switched
to a single-frame mode of operation to avoid the bug.

[email protected]

http://code.google.com/p/google-caja/source/detail?r=5362

Modified:
 /trunk/tests/com/google/caja/plugin/browser-test-case.js
 /trunk/tests/com/google/caja/plugin/es53-test-domado-dom-guest.html

=======================================
--- /trunk/tests/com/google/caja/plugin/browser-test-case.js Sat Mar 23 08:20:01 2013 +++ /trunk/tests/com/google/caja/plugin/browser-test-case.js Thu Apr 18 11:36:23 2013
@@ -621,19 +621,6 @@
   standardImports.assertAsynchronousRequirement =
       frame.tame(frame.markFunction(asyncRequirements.assert));

-  standardImports.crossFrameFreezeBug = frame.tame(frame.markFunction(
-      function () {
-        if (!Object.freeze) { return false; }
-        var iframe = document.createElement('iframe');
-        var where = document.getElementsByTagName('script')[0];
-        where.parentNode.insertBefore(iframe, where);
-        var otherObject = iframe.contentWindow.Object;
-        where.parentNode.removeChild(iframe);
-        var obj = {};
-        otherObject.freeze(obj);
-        return !Object.isFrozen(obj);
-      }));
-
   var jsunitFns = [
       'assert', 'assertContains', 'assertEquals', 'assertEvaluatesToFalse',
       'assertEvaluatesToTrue', 'assertFalse', 'assertHTMLEquals',
=======================================
--- /trunk/tests/com/google/caja/plugin/es53-test-domado-dom-guest.html Wed Apr 17 11:08:30 2013 +++ /trunk/tests/com/google/caja/plugin/es53-test-domado-dom-guest.html Thu Apr 18 11:36:23 2013
@@ -1128,15 +1128,8 @@
     assertEquals('U', childNodes[4].nodeName);
     var TNLproto = Object.getPrototypeOf(childNodes);
     var TNL = TNLproto.constructor;
-    try {
-      assertTrue(Object.isFrozen(TNL));
-      assertTrue(Object.isFrozen(TNLproto));
-    } catch (ex) {
-      if (!crossFrameFreezeBug()) {
-        throw ex;
-      }
-      // TODO(felix8a): known failure handling
-    }
+    assertTrue(Object.isFrozen(TNL));
+    assertTrue(Object.isFrozen(TNLproto));
     pass('testChildNodes');
   });
 </script>
@@ -2835,15 +2828,8 @@
     assertEquals(2, optionsList.selectedIndex);
     var TOLproto = Object.getPrototypeOf(optionsList);
     var TOL = TOLproto.constructor;
-    try {
-      assertTrue(Object.isFrozen(TOL));
-      assertTrue(Object.isFrozen(TOLproto));
-    } catch (ex) {
-      if (!crossFrameFreezeBug()) {
-        throw ex;
-      }
-      // TODO(felix8a): known failure handling
-    }
+    assertTrue(Object.isFrozen(TOL));
+    assertTrue(Object.isFrozen(TOLproto));
     pass('testSelectedIndex');
   });
 </script>

--

--- You received this message because you are subscribed to the Google Groups "Google Caja Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to