diff --git a/cpp/velox/tests/MemoryManagerTest.cc b/cpp/velox/tests/MemoryManagerTest.cc index 0af4ba71ff71..bb102dc2d8c3 100644 --- a/cpp/velox/tests/MemoryManagerTest.cc +++ b/cpp/velox/tests/MemoryManagerTest.cc @@ -392,7 +392,7 @@ TEST_F(MultiMemoryManagerTest, spill) { for (auto& vmm : vmms) { assertCapacitiesMatch(tmm, vmms); - vmm->getMemoryManager()->arbitrator()->shrinkCapacity(allocateSize); + vmm->getMemoryManager()->arbitrator()->shrinkCapacity(allocateSize * numAllocations); assertCapacitiesMatch(tmm, vmms); }