summaryrefslogtreecommitdiffstats
path: root/chrome/test/automation
diff options
context:
space:
mode:
authortony@chromium.org <tony@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-07 17:01:44 +0000
committertony@chromium.org <tony@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-07 17:01:44 +0000
commit84abba65c18ad3746066129990ad46421675d5a2 (patch)
treea3e6193d74f96ab728b3baeeb0a35fdd3dd47e47 /chrome/test/automation
parent0c882b2856e5851765ce89f63d337902a3e6b823 (diff)
downloadchromium_src-84abba65c18ad3746066129990ad46421675d5a2.zip
chromium_src-84abba65c18ad3746066129990ad46421675d5a2.tar.gz
chromium_src-84abba65c18ad3746066129990ad46421675d5a2.tar.bz2
Revert "Revert "Add startup tests that log start script, domcontentloaded, and onload.""
This reverts commit r28209 and relands r28199. The failure seems to have been flaky (it passed on the other bots and on the following run). I want to try to land again. If it fails again, I'll disable the test. TBR=mattm Review URL: http://codereview.chromium.org/268003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28268 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test/automation')
-rw-r--r--chrome/test/automation/automation_messages_internal.h6
-rw-r--r--chrome/test/automation/automation_proxy.cc6
-rw-r--r--chrome/test/automation/automation_proxy.h4
3 files changed, 16 insertions, 0 deletions
diff --git a/chrome/test/automation/automation_messages_internal.h b/chrome/test/automation/automation_messages_internal.h
index c9d04dd..5d009b5 100644
--- a/chrome/test/automation/automation_messages_internal.h
+++ b/chrome/test/automation/automation_messages_internal.h
@@ -1113,4 +1113,10 @@ IPC_BEGIN_MESSAGES(Automation)
int /* tab_handle */,
int /* The font size */)
+ // Returns a metric event duration that was last recorded. Returns -1 if the
+ // event hasn't occurred yet.
+ IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_GetMetricEventDuration,
+ std::string /* event_name */,
+ int /* duration ms */)
+
IPC_END_MESSAGES(Automation)
diff --git a/chrome/test/automation/automation_proxy.cc b/chrome/test/automation/automation_proxy.cc
index a039ffb3..69a363c 100644
--- a/chrome/test/automation/automation_proxy.cc
+++ b/chrome/test/automation/automation_proxy.cc
@@ -342,6 +342,12 @@ bool AutomationProxy::IsURLDisplayed(GURL url) {
return false;
}
+bool AutomationProxy::GetMetricEventDuration(const std::string& event_name,
+ int* duration_ms) {
+ return Send(new AutomationMsg_GetMetricEventDuration(0, event_name,
+ duration_ms));
+}
+
bool AutomationProxy::SetFilteredInet(bool enabled) {
return Send(new AutomationMsg_SetFilteredInet(0, enabled));
}
diff --git a/chrome/test/automation/automation_proxy.h b/chrome/test/automation/automation_proxy.h
index dac3bc3..ce3ff17 100644
--- a/chrome/test/automation/automation_proxy.h
+++ b/chrome/test/automation/automation_proxy.h
@@ -124,6 +124,10 @@ class AutomationProxy : public IPC::Channel::Listener,
// Returns true if one of the tabs in any window displays given url.
bool IsURLDisplayed(GURL url);
+ // Get the duration of the last |event_name| in the browser. Returns
+ // false if the IPC failed to send.
+ bool GetMetricEventDuration(const std::string& event_name, int* duration_ms);
+
// Returns the BrowserProxy for the browser window at the given index,
// transferring ownership of the pointer to the caller.
// On failure, returns NULL.