/toolkit/mozapps/update/test/chrome/test_0151_notify_backgroundCheckError.xul

http://github.com/zpao/v8monkey · Unknown · 50 lines · 40 code · 10 blank · 0 comment · 0 complexity · 8cb468a87b2233467ee153f63113d575 MD5 · raw file

  1. <?xml version="1.0"?>
  2. <!--
  3. /* Any copyright is dedicated to the Public Domain.
  4. * http://creativecommons.org/publicdomain/zero/1.0/
  5. */
  6. -->
  7. <?xml-stylesheet href="chrome://global/skin" type="text/css"?>
  8. <?xml-stylesheet href="chrome://mochikit/content/tests/SimpleTest/test.css" type="text/css"?>
  9. <window title="Test notification when multiple background check errors occur (bug 595455)"
  10. xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
  11. onload="runTestDefault();">
  12. <script type="application/javascript"
  13. src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"/>
  14. <script type="application/javascript"
  15. src="utils.js"/>
  16. <script type="application/javascript">
  17. <![CDATA[
  18. const TESTS = [ {
  19. pageid: PAGEID_ERROR_EXTRA,
  20. extraDelayedCheckFunction: checkErrorExtraPage,
  21. shouldBeHidden: false,
  22. displayedTextElem: "genericBackgroundErrorLabel",
  23. buttonClick: "finish"
  24. } ];
  25. function runTest() {
  26. debugDump("entering");
  27. let url = URL_UPDATE + "?xmlMalformed=1";
  28. setUpdateURLOverride(url);
  29. errorsPrefObserver.init(PREF_APP_UPDATE_BACKGROUNDERRORS,
  30. PREF_APP_UPDATE_BACKGROUNDMAXERRORS);
  31. gAUS.notify(null);
  32. }
  33. ]]>
  34. </script>
  35. <body xmlns="http://www.w3.org/1999/xhtml">
  36. <p id="display"></p>
  37. <div id="content" style="display: none"></div>
  38. <pre id="test"></pre>
  39. </body>
  40. </window>