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

Side by Side Diff: content/renderer/devtools/v8_sampling_profiler_browsertest.cc

Issue 892213004: Mechanical rename of base::debug -> base::trace_event for /content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@move_trace_part3_1
Patch Set: Rebase. Created 5 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/trace_event/trace_event.h" 5 #include "base/trace_event/trace_event.h"
6 #include "content/renderer/devtools/v8_sampling_profiler.h" 6 #include "content/renderer/devtools/v8_sampling_profiler.h"
7 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
8 8
9 using base::debug::CategoryFilter; 9 using base::trace_event::CategoryFilter;
10 using base::debug::TraceLog; 10 using base::trace_event::TraceLog;
11 using base::debug::TraceOptions; 11 using base::trace_event::TraceOptions;
12 12
13 namespace content { 13 namespace content {
14 14
15 class V8SamplingProfilerTest : public testing::Test {}; 15 class V8SamplingProfilerTest : public testing::Test {};
16 16
17 TEST_F(V8SamplingProfilerTest, V8SamplingEventFired) { 17 TEST_F(V8SamplingProfilerTest, V8SamplingEventFired) {
18 scoped_ptr<V8SamplingProfiler> sampling_profiler(new V8SamplingProfiler()); 18 scoped_ptr<V8SamplingProfiler> sampling_profiler(new V8SamplingProfiler());
19 sampling_profiler->EnableSamplingEventForTesting(); 19 sampling_profiler->EnableSamplingEventForTesting();
20 TraceLog::GetInstance()->SetEnabled( 20 TraceLog::GetInstance()->SetEnabled(
21 CategoryFilter(TRACE_DISABLED_BY_DEFAULT("v8_cpu_profile")), 21 CategoryFilter(TRACE_DISABLED_BY_DEFAULT("v8_cpu_profile")),
22 TraceLog::RECORDING_MODE, TraceOptions()); 22 TraceLog::RECORDING_MODE, TraceOptions());
23 sampling_profiler->WaitSamplingEventForTesting(); 23 sampling_profiler->WaitSamplingEventForTesting();
24 TraceLog::GetInstance()->SetDisabled(); 24 TraceLog::GetInstance()->SetDisabled();
25 } 25 }
26 26
27 } // namespace content 27 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/devtools/v8_sampling_profiler.cc ('k') | content/renderer/render_frame_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698