Parallelize Tests in CI (+ Refactor and Improvements) #21109
We could re-write this PR to not include the heavy use of Azure DevOps templates. Which would make for smaller and more targeted changes, and be easier to review.
Let us know; We'd be very glad to see this improvement land at this repo, so CI can run faster here.
Thank you for asking. I haven't noticed any negative impact on performance. The speed bottleneck of running the tests is not in spawning the child_process (which might take less than 1 second), but in running the tests themselves.
Using separate child_process allows us to selectively choose what we want to run, and rerun them if they fail (#21295). Using this I have improved the overall performance and test pass rate.
With that being said there is still room for improvement. If you have noticed we use
Without having these separately, running them in parallel is just impossible.
Yes, and I think this is a better approach. However, if you don't like this, it has an easy fix. Here instead of throwing an error, we can run all the tests: