| Index: test/cctest/test-heap.cc
|
| diff --git a/test/cctest/test-heap.cc b/test/cctest/test-heap.cc
|
| index 86be15a5ca272aad04ad804ad589c322f7ca31a4..aeab4014b7453403706d3a2858aa0593aa170570 100644
|
| --- a/test/cctest/test-heap.cc
|
| +++ b/test/cctest/test-heap.cc
|
| @@ -1233,9 +1233,8 @@ TEST(GrowAndShrinkNewSpace) {
|
| new_capacity = new_space->Capacity();
|
| ASSERT_EQ(2 * old_capacity, new_capacity);
|
|
|
| - // Fill up new space to the point that it exceeds old capacity.
|
| - while (new_space->SizeAsInt() <= old_capacity) {
|
| - Handle<FixedArray> filler = FACTORY->NewFixedArray(1000, NOT_TENURED);
|
| + // Fill up new space to the point that it is almost full.
|
| + while (new_space->SizeAsInt() + FixedArray::SizeFor(1000) < new_capacity) {
|
| ASSERT(HEAP->InNewSpace(*FACTORY->NewFixedArray(1000, NOT_TENURED)));
|
| }
|
|
|
| @@ -1263,28 +1262,3 @@ TEST(GrowAndShrinkNewSpace) {
|
| new_capacity = new_space->Capacity();
|
| ASSERT_EQ(old_capacity, new_capacity);
|
| }
|
| -
|
| -
|
| -class HeapIteratorTestHelper {
|
| - public:
|
| - HeapIteratorTestHelper(Object* a, Object* b)
|
| - : a_(a), b_(b), a_found_(false), b_found_(false) {}
|
| - bool a_found() { return a_found_; }
|
| - bool b_found() { return b_found_; }
|
| - void IterateHeap() {
|
| - HeapIterator iterator;
|
| - for (HeapObject* obj = iterator.next();
|
| - obj != NULL;
|
| - obj = iterator.next()) {
|
| - if (obj == a_)
|
| - a_found_ = true;
|
| - else if (obj == b_)
|
| - b_found_ = true;
|
| - }
|
| - }
|
| - private:
|
| - Object* a_;
|
| - Object* b_;
|
| - bool a_found_;
|
| - bool b_found_;
|
| -};
|
|
|