(x)
| 2 | // with an async delay and GC call between each. |
| 3 | |
| 4 | function tick (x) { |
| 5 | return new Promise((resolve) => { |
| 6 | setImmediate(function ontick () { |
| 7 | if (--x === 0) { |
| 8 | resolve(); |
| 9 | } else { |
| 10 | setImmediate(ontick); |
| 11 | } |
| 12 | }); |
| 13 | }); |
| 14 | } |
| 15 | |
| 16 | async function runGCTests (tests) { |
| 17 | // Break up test list into a list of lists of the form |