/* vim: set ts=2 et sw=2 tw=80: */ /* Any copyright is dedicated to the Public Domain. http://creativecommons.org/publicdomain/zero/1.0/ */ "use strict"; // Tests that selecting an element with the 'Inspect Element' context // menu during a page reload doesn't cause the markup view to become empty. // See https://bugzilla.mozilla.org/show_bug.cgi?id=1036324 const server = createTestHTTPServer(); // Register a slow image handler so we can simulate a long time between // a reload and the load event firing. server.registerContentType("gif", "image/gif"); server.registerPathHandler("/slow.gif", function (metadata, response) { info("Image has been requested"); response.processAsync(); setTimeout(() => { info("Image is responding"); response.finish(); }, 500); }); // Test page load events. const TEST_URL = "data:text/html," + "" + "
" + "" + "Slow script
" + "" + "" + "