Home | History | Annotate | Download | only in resources
      1 <html manifest="origin-delete-iframe.manifest">
      2 <script>
      3 // iframe-1 is expected to succeed.
      4 applicationCache.oncached = function() { parent.postMessage("PASS - cached iframe-1", "*"); };
      5 applicationCache.onerror = function() { parent.postMessage("FAIL - error caching iframe-1, expected this to succeed", "*"); };
      6 applicationCache.onnoupdate = function() { parent.postMessage("FAIL - no update iframe-1, all caches should have been deleted before this test", "*"); };
      7 
      8 
      9 function frameMessageReceived(event) {
     10     if (event.data === "appcache_status") {
     11         parent.postMessage("appcache_status=" + applicationCache.status, "*");
     12     } else {
     13         parent.postMessage("FAIL - unrecognized message", "*");
     14     }
     15 }
     16 
     17 window.addEventListener("message", frameMessageReceived, false);
     18 
     19 </script>
     20 </html>
     21