From 3be0269ec9121cd1dc6827ca9f9bc217dfd3bedf Mon Sep 17 00:00:00 2001 From: "pfeldman@chromium.org" Date: Tue, 15 Dec 2009 18:11:44 +0000 Subject: DevTools: fix sanity tests insanity. TBR=dglazkov git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34572 0039d316-1c4b-4281-b951-d872f2087c98 --- webkit/glue/devtools/js/tests.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'webkit') diff --git a/webkit/glue/devtools/js/tests.js b/webkit/glue/devtools/js/tests.js index 59de44d..53ce7f2 100644 --- a/webkit/glue/devtools/js/tests.js +++ b/webkit/glue/devtools/js/tests.js @@ -227,7 +227,7 @@ TestSuite.prototype.testEnableResourcesTab = function() { this.showPanel('resources'); var test = this; - this.addSniffer(WebInspector, 'addResource', + this.addSniffer(WebInspector, '_addResource', function(identifier, payload) { test.assertEquals('simple_page.html', payload.lastPathComponent); WebInspector.panels.resources.refresh(); @@ -315,7 +315,7 @@ TestSuite.prototype.testResourceHeaders = function() { var responseOk = false; var timingOk = false; - this.addSniffer(WebInspector, 'addResource', + this.addSniffer(WebInspector, '_addResource', function(identifier, payload) { var resource = this.resources[identifier]; if (resource.mainResource) { @@ -331,7 +331,7 @@ TestSuite.prototype.testResourceHeaders = function() { this.addSniffer(WebInspector, 'updateResource', function(identifier, payload) { var resource = this.resources[identifier]; - if (resource.mainResource) { + if (!resource || resource.mainResource) { // We are only interested in secondary resources in this test. return; } @@ -375,7 +375,7 @@ TestSuite.prototype.testCachedResourceMimeType = function() { this.addSniffer(WebInspector, 'updateResource', function(identifier, payload) { var resource = this.resources[identifier]; - if (resource.mainResource) { + if (!resource || resource.mainResource) { // We are only interested in secondary resources in this test. return; } -- cgit v1.1