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

Unified Diff: test/cctest/test-profile-generator.cc

Issue 152643006: Make LeakSanitizer happy, part 1. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 10 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 | « test/cctest/test-parsing.cc ('k') | test/cctest/test-regexp.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-profile-generator.cc
diff --git a/test/cctest/test-profile-generator.cc b/test/cctest/test-profile-generator.cc
index e06063dc560236a9d68fceb4b3bf7ac8fa1d32ed..c3198b1512f6f531df28f6114b86f07ccf7b2d85 100644
--- a/test/cctest/test-profile-generator.cc
+++ b/test/cctest/test-profile-generator.cc
@@ -48,42 +48,42 @@ using i::Vector;
TEST(ProfileNodeFindOrAddChild) {
ProfileTree tree;
- ProfileNode node(&tree, NULL);
+ ProfileNode* node = tree.root();
CodeEntry entry1(i::Logger::FUNCTION_TAG, "aaa");
- ProfileNode* childNode1 = node.FindOrAddChild(&entry1);
+ ProfileNode* childNode1 = node->FindOrAddChild(&entry1);
CHECK_NE(NULL, childNode1);
- CHECK_EQ(childNode1, node.FindOrAddChild(&entry1));
+ CHECK_EQ(childNode1, node->FindOrAddChild(&entry1));
CodeEntry entry2(i::Logger::FUNCTION_TAG, "bbb");
- ProfileNode* childNode2 = node.FindOrAddChild(&entry2);
+ ProfileNode* childNode2 = node->FindOrAddChild(&entry2);
CHECK_NE(NULL, childNode2);
CHECK_NE(childNode1, childNode2);
- CHECK_EQ(childNode1, node.FindOrAddChild(&entry1));
- CHECK_EQ(childNode2, node.FindOrAddChild(&entry2));
+ CHECK_EQ(childNode1, node->FindOrAddChild(&entry1));
+ CHECK_EQ(childNode2, node->FindOrAddChild(&entry2));
CodeEntry entry3(i::Logger::FUNCTION_TAG, "ccc");
- ProfileNode* childNode3 = node.FindOrAddChild(&entry3);
+ ProfileNode* childNode3 = node->FindOrAddChild(&entry3);
CHECK_NE(NULL, childNode3);
CHECK_NE(childNode1, childNode3);
CHECK_NE(childNode2, childNode3);
- CHECK_EQ(childNode1, node.FindOrAddChild(&entry1));
- CHECK_EQ(childNode2, node.FindOrAddChild(&entry2));
- CHECK_EQ(childNode3, node.FindOrAddChild(&entry3));
+ CHECK_EQ(childNode1, node->FindOrAddChild(&entry1));
+ CHECK_EQ(childNode2, node->FindOrAddChild(&entry2));
+ CHECK_EQ(childNode3, node->FindOrAddChild(&entry3));
}
TEST(ProfileNodeFindOrAddChildForSameFunction) {
const char* aaa = "aaa";
ProfileTree tree;
- ProfileNode node(&tree, NULL);
+ ProfileNode* node = tree.root();
CodeEntry entry1(i::Logger::FUNCTION_TAG, aaa);
- ProfileNode* childNode1 = node.FindOrAddChild(&entry1);
+ ProfileNode* childNode1 = node->FindOrAddChild(&entry1);
CHECK_NE(NULL, childNode1);
- CHECK_EQ(childNode1, node.FindOrAddChild(&entry1));
+ CHECK_EQ(childNode1, node->FindOrAddChild(&entry1));
// The same function again.
CodeEntry entry2(i::Logger::FUNCTION_TAG, aaa);
- CHECK_EQ(childNode1, node.FindOrAddChild(&entry2));
+ CHECK_EQ(childNode1, node->FindOrAddChild(&entry2));
// Now with a different security token.
CodeEntry entry3(i::Logger::FUNCTION_TAG, aaa);
- CHECK_EQ(childNode1, node.FindOrAddChild(&entry3));
+ CHECK_EQ(childNode1, node->FindOrAddChild(&entry3));
}
« no previous file with comments | « test/cctest/test-parsing.cc ('k') | test/cctest/test-regexp.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698