| Index: test/cctest/test-heap-profiler.cc
|
| diff --git a/test/cctest/test-heap-profiler.cc b/test/cctest/test-heap-profiler.cc
|
| index db2243a3f0445f847838d5bbe984ef6df5ffe7e9..988e56de72ca0ece0643fe745245436cda9b7f8b 100644
|
| --- a/test/cctest/test-heap-profiler.cc
|
| +++ b/test/cctest/test-heap-profiler.cc
|
| @@ -2062,6 +2062,18 @@ v8::DeclareExtension kHeapProfilerExtensionDeclaration(
|
|
|
|
|
| // This is an example of using checking of JS allocations tracking in a test.
|
| +TEST(AllocationProfilerString) {
|
| + v8::internal::Isolate::Current()->enable_allocation_profiler();
|
| + const char* extensions[] = { HeapProfilerExtension::kName };
|
| + v8::ExtensionConfiguration config(1, extensions);
|
| + LocalContext env(&config);
|
| + v8::HandleScope scope(env->GetIsolate());
|
| + HeapObjectsTracker tracker;
|
| + CompileRun("var a = new String(" ");findUntrackedObjects();");
|
| +}
|
| +
|
| +
|
| +// This is an example of using checking of JS allocations tracking in a test.
|
| TEST(HeapObjectsTracker) {
|
| const char* extensions[] = { HeapProfilerExtension::kName };
|
| v8::ExtensionConfiguration config(1, extensions);
|
|
|