regression test for Issue 10701

- The test isn't 100% reliable because it depends
  on the GC and array append cache state.