Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(156)

Unified Diff: chrome/test/perf/rendering/throughput_tests.cc

Issue 10911268: Add some TraceAnalyzer utility methods to simplify test code (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/perf/rendering/latency_tests.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/perf/rendering/throughput_tests.cc
diff --git a/chrome/test/perf/rendering/throughput_tests.cc b/chrome/test/perf/rendering/throughput_tests.cc
index 76e1f9390bd1c2a38c009e3d43f770949d001a62..f7d7749383c512404549a3511c4cfefb4f2113f2 100644
--- a/chrome/test/perf/rendering/throughput_tests.cc
+++ b/chrome/test/perf/rendering/throughput_tests.cc
@@ -341,8 +341,8 @@ class ThroughputTest : public BrowserPerfTest {
// Check if GPU is rendering:
analyzer.reset(TraceAnalyzer::Create(json_events));
- bool ran_on_gpu = (analyzer->FindEvents(Query::EventName() ==
- Query::String("SwapBuffers"), &events_gpu) > 0u);
+ bool ran_on_gpu = (analyzer->FindEvents(
+ Query::EventNameIs("SwapBuffers"), &events_gpu) > 0u);
LOG(INFO) << "Mode: " << (ran_on_gpu ? "GPU" : "Software");
EXPECT_EQ(use_gpu_, ran_on_gpu);
@@ -355,8 +355,8 @@ class ThroughputTest : public BrowserPerfTest {
// Search for frame ticks. We look for both SW and GPU frame ticks so that
// the test can verify that only one or the other are found.
analyzer.reset(TraceAnalyzer::Create(json_events));
- Query query_sw = Query::EventName() == Query::String("TestFrameTickSW");
- Query query_gpu = Query::EventName() == Query::String("TestFrameTickGPU");
+ Query query_sw = Query::EventNameIs("TestFrameTickSW");
+ Query query_gpu = Query::EventNameIs("TestFrameTickGPU");
analyzer->FindEvents(query_sw, &events_sw);
analyzer->FindEvents(query_gpu, &events_gpu);
TraceEventVector* frames = NULL;
« no previous file with comments | « chrome/test/perf/rendering/latency_tests.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698