From 8c7074e5db07df137db7b1210de7a41d2da334cd Mon Sep 17 00:00:00 2001 From: Bobby Holley Date: Thu, 27 Aug 2009 11:38:10 +0200 Subject: [PATCH] Bug 510001 - Fixed the hardcoded port and added an onerror debugging dump for the test for bug 507902. r=lumpy --- layout/generic/test/test_bug507902.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/layout/generic/test/test_bug507902.html b/layout/generic/test/test_bug507902.html index bc9b8a482f73..b4523ebf3d73 100644 --- a/layout/generic/test/test_bug507902.html +++ b/layout/generic/test/test_bug507902.html @@ -40,7 +40,8 @@ gWindowUtils = window.QueryInterface(Ci.nsIInterfaceRequestor). // We have a separate copy of the icons in the test directory to // avoid any firefox caching mechanisms that might affect the // behavior of the load. -var baseURL = "http://localhost:8888/tests/layout/generic/test/"; +var us = window.location.href; +var baseURL = us.substring(0, us.lastIndexOf('/') + 1); var loadIconFilename = "file_LoadingImageReference.png"; var imageFilename = "file_Dolske.png"; var brokenIconFilename = "file_BrokenImageReference.png"; @@ -99,6 +100,9 @@ function loadBrokenIconReference() { // Debugging - Let's see if setting onload after src is a problem testImageElem.onload = function(event) { dump("test_bug507902.html DEBUG - uh oh, placeholder onload 1 called\n");}; + // Debug - Figure out if we're getting an onerror instead of onload + testImageElem.onerror = function(event) {dump("test_bug507902.html DEBUG - Got onerror for testImageElem!\n");}; + testImageElem.src = baseURL + brokenIconFilename; stageTransition(); }