Merge "Rewrite test data logic to make it faster" am: 83e9cfe291

Original change: https://android-review.googlesource.com/c/platform/build/+/1326014

Change-Id: I1ef75ceda67b8735217fe69af81e6b9d1481894e