Index: base/trace_event/process_memory_maps_dump_provider_unittest.cc |
diff --git a/base/trace_event/process_memory_maps_dump_provider_unittest.cc b/base/trace_event/process_memory_maps_dump_provider_unittest.cc |
index 5416e119960f790858386de5bafb167d549da6fe..fcb9eaff4f19b2913fa12d4be5a7dc2bd42a4f27 100644 |
--- a/base/trace_event/process_memory_maps_dump_provider_unittest.cc |
+++ b/base/trace_event/process_memory_maps_dump_provider_unittest.cc |
@@ -110,6 +110,7 @@ TEST(ProcessMemoryMapsDumpProviderTest, ParseProcSmaps) { |
const uint32 kProtR = ProcessMemoryMaps::VMRegion::kProtectionFlagsRead; |
const uint32 kProtW = ProcessMemoryMaps::VMRegion::kProtectionFlagsWrite; |
const uint32 kProtX = ProcessMemoryMaps::VMRegion::kProtectionFlagsExec; |
+ const MemoryDumpArgs dump_args = {MemoryDumpArgs::LEVEL_OF_DETAIL_HIGH}; |
auto pmmdp = ProcessMemoryMapsDumpProvider::GetInstance(); |
@@ -118,21 +119,21 @@ TEST(ProcessMemoryMapsDumpProviderTest, ParseProcSmaps) { |
std::ifstream non_existent_file("/tmp/does-not-exist"); |
ProcessMemoryMapsDumpProvider::proc_smaps_for_testing = &non_existent_file; |
CHECK_EQ(false, non_existent_file.good()); |
- pmmdp->OnMemoryDump(&pmd_invalid); |
+ pmmdp->OnMemoryDump(dump_args, &pmd_invalid); |
ASSERT_FALSE(pmd_invalid.has_process_mmaps()); |
// Emulate an empty /proc/self/smaps. |
std::ifstream empty_file("/dev/null"); |
ProcessMemoryMapsDumpProvider::proc_smaps_for_testing = &empty_file; |
CHECK_EQ(true, empty_file.good()); |
- pmmdp->OnMemoryDump(&pmd_invalid); |
+ pmmdp->OnMemoryDump(dump_args, &pmd_invalid); |
ASSERT_FALSE(pmd_invalid.has_process_mmaps()); |
// Parse the 1st smaps file. |
ProcessMemoryDump pmd_1(nullptr /* session_state */); |
std::istringstream test_smaps_1(kTestSmaps1); |
ProcessMemoryMapsDumpProvider::proc_smaps_for_testing = &test_smaps_1; |
- pmmdp->OnMemoryDump(&pmd_1); |
+ pmmdp->OnMemoryDump(dump_args, &pmd_1); |
ASSERT_TRUE(pmd_1.has_process_mmaps()); |
const auto& regions_1 = pmd_1.process_mmaps()->vm_regions(); |
ASSERT_EQ(2UL, regions_1.size()); |
@@ -163,7 +164,7 @@ TEST(ProcessMemoryMapsDumpProviderTest, ParseProcSmaps) { |
ProcessMemoryDump pmd_2(nullptr /* session_state */); |
std::istringstream test_smaps_2(kTestSmaps2); |
ProcessMemoryMapsDumpProvider::proc_smaps_for_testing = &test_smaps_2; |
- pmmdp->OnMemoryDump(&pmd_2); |
+ pmmdp->OnMemoryDump(dump_args, &pmd_2); |
ASSERT_TRUE(pmd_2.has_process_mmaps()); |
const auto& regions_2 = pmd_2.process_mmaps()->vm_regions(); |
ASSERT_EQ(1UL, regions_2.size()); |