def MeasurePage(self, page, tab, results): # Wait for all tabs to finish loading. for i in xrange(len(tab.browser.tabs)): t = tab.browser.tabs[i] t.WaitForDocumentReadyStateToBeComplete() startup_metric.StartupMetric().AddResults(tab, results)
def ValidateAndMeasurePage(self, page, tab, results): tab.WaitForDocumentReadyStateToBeComplete() # Record CPU usage from browser start to when the foreground page is loaded. self._cpu_metric.Stop(None, None) self._cpu_metric.AddResults(tab, results, 'cpu_utilization') startup_metric.StartupMetric().AddResults(tab, results)
def MeasurePage(self, page, tab, results): tab.browser.foreground_tab.WaitForDocumentReadyStateToBeComplete() # Record CPU usage from browser start to when all pages have loaded. self._cpu_metric.Stop(None, None) self._cpu_metric.AddResults(tab, results, 'cpu_utilization') startup_metric.StartupMetric().AddResults(tab, results) # TODO(jeremy): Measure time to load - first, last and frontmost tab here.
def MeasurePage(self, page, tab, results): # Wait for all tabs to finish loading. for i in xrange(len(tab.browser.tabs)): t = tab.browser.tabs[i] t.WaitForDocumentReadyStateToBeComplete() # Record CPU usage from browser start to when all pages have loaded. self._cpu_metric.Stop(None, None) self._cpu_metric.AddResults(tab, results, 'cpu_utilization') startup_metric.StartupMetric().AddResults(tab, results)
def MeasurePage(self, page, tab, results): startup_metric.StartupMetric().AddResults(tab, results)
def ValidateAndMeasurePage(self, page, tab, results): keychain_metric.KeychainMetric().AddResults(tab, results) startup_metric.StartupMetric().AddResults(tab, results)