Index: test/cctest/test-serialize.cc |
diff --git a/test/cctest/test-serialize.cc b/test/cctest/test-serialize.cc |
index ac716a4c5c5e3c80f7342a72d503d5dc730ecc2f..0c0e522803442f12fa64a322710117624b447213 100644 |
--- a/test/cctest/test-serialize.cc |
+++ b/test/cctest/test-serialize.cc |
@@ -867,6 +867,8 @@ TEST(SerializeToplevelLargeString) { |
CHECK_EQ(6 * 1000000, Handle<String>::cast(copy_result)->length()); |
CHECK(isolate->heap()->InSpace(HeapObject::cast(*copy_result), LO_SPACE)); |
+ // Make sure we do not serialize too much, e.g. include the source string. |
+ CHECK_LT(cache->length(), 7000000); |
delete cache; |
source.Dispose(); |