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

Side by Side Diff: Source/platform/heap/BlinkGCMemoryDumpProviderTest.cpp

Issue 1281673003: [tracing] Adding support for light dumps in blink gc dump provider (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixing test. 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 unified diff | Download patch
« no previous file with comments | « Source/platform/heap/BlinkGCMemoryDumpProvider.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "config.h" 5 #include "config.h"
6 #include "platform/heap/BlinkGCMemoryDumpProvider.h" 6 #include "platform/heap/BlinkGCMemoryDumpProvider.h"
7 7
8 #include "public/platform/Platform.h" 8 #include "public/platform/Platform.h"
9 #include "public/platform/WebProcessMemoryDump.h" 9 #include "public/platform/WebProcessMemoryDump.h"
10 #include "wtf/Threading.h" 10 #include "wtf/Threading.h"
11 11
12 #include <gtest/gtest.h> 12 #include <gtest/gtest.h>
13 13
14 namespace blink { 14 namespace blink {
15 15
16 TEST(BlinkGCDumpProviderTest, MemoryDump) 16 TEST(BlinkGCDumpProviderTest, MemoryDump)
17 { 17 {
18 WebProcessMemoryDump* dump = Platform::current()->createProcessMemoryDump() ; 18 WebProcessMemoryDump* dump = Platform::current()->createProcessMemoryDump() ;
19 ASSERT(dump); 19 ASSERT(dump);
20 BlinkGCMemoryDumpProvider::instance()->onMemoryDump(WebMemoryDumpLevelOfDeta il::High, dump); 20 BlinkGCMemoryDumpProvider::instance()->onMemoryDump(WebMemoryDumpLevelOfDeta il::High, dump);
21 ASSERT(dump->getMemoryAllocatorDump(String::format("blink_gc/thread_%lu", st atic_cast<unsigned long>(WTF::currentThread())))); 21 ASSERT(dump->getMemoryAllocatorDump(String::format("blink_gc")));
22 ASSERT(dump->getMemoryAllocatorDump(String::format("blink_gc/thread_%lu/allo cated_objects", static_cast<unsigned long>(WTF::currentThread())))); 22 ASSERT(dump->getMemoryAllocatorDump(String::format("blink_gc/allocated_objec ts")));
23 } 23 }
24 24
25 } // namespace blink 25 } // namespace blink
OLDNEW
« no previous file with comments | « Source/platform/heap/BlinkGCMemoryDumpProvider.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698