OLD | NEW |
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 <stddef.h> |
| 6 |
5 #include "base/json/json_reader.h" | 7 #include "base/json/json_reader.h" |
6 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
7 #include "base/trace_event/trace_buffer.h" | 9 #include "base/trace_event/trace_buffer.h" |
8 #include "base/trace_event/trace_event.h" | 10 #include "base/trace_event/trace_event.h" |
9 #include "content/public/test/render_view_test.h" | 11 #include "content/public/test/render_view_test.h" |
10 #include "content/renderer/devtools/v8_sampling_profiler.h" | 12 #include "content/renderer/devtools/v8_sampling_profiler.h" |
11 | 13 |
12 using base::DictionaryValue; | 14 using base::DictionaryValue; |
13 using base::ListValue; | 15 using base::ListValue; |
14 using base::Value; | 16 using base::Value; |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
138 } | 140 } |
139 | 141 |
140 TEST_F(V8SamplingProfilerTest, V8SamplingSamplesCollected) { | 142 TEST_F(V8SamplingProfilerTest, V8SamplingSamplesCollected) { |
141 CollectTrace(0, 1); | 143 CollectTrace(0, 1); |
142 int sample_events_count = CountEvents("V8Sample"); | 144 int sample_events_count = CountEvents("V8Sample"); |
143 CHECK_LT(0, sample_events_count); | 145 CHECK_LT(0, sample_events_count); |
144 base::RunLoop().RunUntilIdle(); | 146 base::RunLoop().RunUntilIdle(); |
145 } | 147 } |
146 | 148 |
147 } // namespace content | 149 } // namespace content |
OLD | NEW |