Make heap exhaustion more robust in art-tests

Repeat heap exhaustion loop a couple of times to make sure there is no
space left on the Java heap. This is essential as we now report OOME
even when 1% of the heap is available for allocation. Repetition ensures
that even the 1% available heap is also consumed.

Test: art/test/testrunner/testrunner.py
Bug: 144525957
Change-Id: Iec5e6ae59c95f7ae5e8c13dc47bcc43a76795447
4 files changed