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

Unified Diff: base/profiler/stack_sampling_profiler_unittest.cc

Issue 1316153002: StackSamplingProfiler: collect partial bursts if the profiler is stopped early (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: Created 5 years, 4 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 | « base/profiler/stack_sampling_profiler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/profiler/stack_sampling_profiler_unittest.cc
diff --git a/base/profiler/stack_sampling_profiler_unittest.cc b/base/profiler/stack_sampling_profiler_unittest.cc
index d57a151f5e990e6cd94f319a57f1acc91b9b26f8..1426f4647f6154efc8faebe10f071927ae762dbc 100644
--- a/base/profiler/stack_sampling_profiler_unittest.cc
+++ b/base/profiler/stack_sampling_profiler_unittest.cc
@@ -346,7 +346,7 @@ TEST(StackSamplingProfilerTest, MAYBE_StopDuringInterBurstInterval) {
EXPECT_EQ(1u, profiles[0].samples.size());
}
-// Checks that only completed call stack profiles are captured.
+// Checks that incomplete call stack profiles are captured.
#if defined(STACK_SAMPLING_PROFILER_SUPPORTED)
#define MAYBE_StopDuringInterSampleInterval StopDuringInterSampleInterval
#else
@@ -361,7 +361,8 @@ TEST(StackSamplingProfilerTest, MAYBE_StopDuringInterSampleInterval) {
std::vector<CallStackProfile> profiles;
CaptureProfiles(params, TimeDelta::FromMilliseconds(50), &profiles);
- EXPECT_TRUE(profiles.empty());
+ ASSERT_EQ(1u, profiles.size());
+ EXPECT_EQ(1u, profiles[0].samples.size());
}
// Checks that we can destroy the profiler while profiling.
« no previous file with comments | « base/profiler/stack_sampling_profiler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698