Revision: 5451
Author:   [email protected]
Date:     Mon Jun 17 13:22:24 2013
Log:      admit MAGICAL_UNICORN for firefox 22 (beta)
https://codereview.appspot.com/10341043

some automode tests use an impossibly strict severity level
named MAGICAL_UNICORN to force a switch to es53.

repairES5 validates severity levels and rejects MAGICAL_UNICORN,
replacing it with SAFE_SPEC_VIOLATION.

firefox 22 meets the standard of SAFE_SPEC_VIOLATION, so the
automode tests fail to switch to es53, causing the tests to fail.

this fix admits MAGICAL_UNICORN exists

R=kpreid2


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

Modified:
 /trunk/src/com/google/caja/ses/repairES5.js

=======================================
--- /trunk/src/com/google/caja/ses/repairES5.js Thu Jun 13 12:07:58 2013
+++ /trunk/src/com/google/caja/ses/repairES5.js Mon Jun 17 13:22:24 2013
@@ -219,7 +219,7 @@
     if (severityName) {
       var sev = ses.severities[severityName];
       if (sev && typeof sev.level === 'number' &&
-        sev.level >= ses.severities.SAFE.level &&
+        sev.level >= ses.severities.MAGICAL_UNICORN.level &&
         sev.level < ses.severities.NOT_SUPPORTED.level) {
         // do nothing
       } else {
@@ -4036,7 +4036,8 @@
         postSeverity = severities.NEW_SYMPTOM;
       }

-      if (postSeverity !== severities.SAFE && disposition(kludge).permit) {
+      if (postSeverity.level > severities.SAFE.level
+          && disposition(kludge).permit) {
         logger.warn('Problem ignored by configuration (' +
             postSeverity.description + '): ' + kludge.description);
       } else {

--

--- 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