Parallelize required tests and build jobs #4715
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
An issue currently is that the Windows tests are by far the slowest which drags everything down. This is mainly because it takes so long to install dependencies:
Above time to merge was approximately
1m24s + 8m44s = 10m8s
For integration tests the Windows ones are optional since we expect them to rarely fail, so they rely on us to notice. I don't think we should do this for the unit tests though as we want auto merge to be reliable and they're more likely to fail.
This change kicks off the required unit test and integration test jobs immediately and then waits for the build job to finish after installing dependencies, effectively saving up to the build job time (~1m30s) from the required checks. We only do this for the subset of jobs that are marked as required to merge to be a good GH actions citizen and not use agents so eagerly, this should also ensure the required unit test job will get a Windows agent before the optional integration test one.
Above time to merge was approximately
max(1m18s, 6m48s) = 6m48s
- probably just got lucky here or unlucky in the top one for the individual job times