SI-8924 Improve test safety

Make the test less dangerous: no need to hold allocations;
stop allocating if the heap is grown, as it probably doesn't
even matter why it grew, for purposes of the test.