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

Side by Side Diff: test/cctest/heap-tester.h

Issue 1293283003: [heap,cctest] Get rid of protected-for-sake-of-testing scope. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add heap-tester.h to cctest.gyp 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 | « test/cctest/cctest.gyp ('k') | test/cctest/test-alloc.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef HEAP_TESTER_H_
6 #define HEAP_TESTER_H_
7
8 #include "src/handles.h"
9 #include "src/heap/spaces.h"
10
11 // Tests that should have access to private methods of {v8::internal::Heap}.
12 // Those tests need to be defined using HEAP_TEST(Name) { ... }.
13 #define HEAP_TEST_METHODS(V) \
14 V(GCFlags) \
15 V(MarkCompactCollector) \
16 V(NoPromotion) \
17 V(NumberStringCacheSize) \
18 V(ObjectGroups) \
19 V(Promotion) \
20 V(Regression39128) \
21 V(ResetWeakHandle) \
22 V(StressHandles) \
23 V(TestSizeOfObjects) \
24 V(WriteBarriersInCopyJSObject)
25
26
27 #define HEAP_TEST(Name) \
28 CcTest register_test_##Name(v8::internal::HeapTester::Test##Name, __FILE__, \
29 #Name, NULL, true, true); \
30 void v8::internal::HeapTester::Test##Name()
31
32
33 #define THREADED_HEAP_TEST(Name) \
34 RegisterThreadedTest register_##Name(v8::internal::HeapTester::Test##Name, \
35 #Name); \
36 /* */ HEAP_TEST(Name)
37
38
39 namespace v8 {
40 namespace internal {
41
42 class HeapTester {
43 public:
44 #define DECLARE_STATIC(Name) static void Test##Name();
45
46 HEAP_TEST_METHODS(DECLARE_STATIC)
47 #undef HEAP_TEST_METHODS
48
49 /* test-alloc.cc */
50 static AllocationResult AllocateAfterFailures();
51 static Handle<Object> TestAllocateAfterFailures();
52
53 /* test-api.cc */
54 static void ResetWeakHandle(bool global_gc);
55 };
56 }
57 }
58
59 #endif // HEAP_TESTER_H_
OLDNEW
« no previous file with comments | « test/cctest/cctest.gyp ('k') | test/cctest/test-alloc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698