fix for TestHeapEntryIdsAndGC
authorloislo@chromium.org <loislo@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Tue, 27 Mar 2012 12:25:05 +0000 (12:25 +0000)
committerloislo@chromium.org <loislo@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Tue, 27 Mar 2012 12:25:05 +0000 (12:25 +0000)
BUG=none
TEST=none

Review URL: https://chromiumcodereview.appspot.com/9864035

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11163 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

test/cctest/test-heap-profiler.cc

index 7ecaa35..d6adfea 100644 (file)
@@ -425,9 +425,11 @@ TEST(HeapEntryIdsAndGC) {
       v8::HeapProfiler::TakeSnapshot(s2_str);
 
   // Second snapshot has one more string, it is it's name 's2'.
-  CHECK_EQ_SNAPSHOT_OBJECT_ID(
-    snapshot1->GetMaxSnapshotJSObjectId(),
-    snapshot2->GetMaxSnapshotJSObjectId());
+  CHECK(
+    snapshot1->GetMaxSnapshotJSObjectId() <=
+    snapshot2->GetMaxSnapshotJSObjectId() &&
+    snapshot2->GetMaxSnapshotJSObjectId() <=
+    snapshot1->GetMaxSnapshotJSObjectId() + i::HeapObjectsMap::kObjectIdStep);
 
   const v8::HeapGraphNode* global1 = GetGlobalObject(snapshot1);
   const v8::HeapGraphNode* global2 = GetGlobalObject(snapshot2);