Make apex tests parallel
Mark all the apex tests and subtests with t.Parallel(), which will allow
the test runner to run them in parallel. Reduces the time required to
run the apex tests from 70s to 9.7s.
Test: go test ./apex
Flag: EXEMPT test only
Change-Id: I08bd3cb4d8eec1f9520c1118b4525aa79e95288e
diff --git a/apex/container_test.go b/apex/container_test.go
index d28b1a6..d1dfb9c 100644
--- a/apex/container_test.go
+++ b/apex/container_test.go
@@ -27,6 +27,7 @@
}
func TestApexDepsContainers(t *testing.T) {
+ t.Parallel()
result := android.GroupFixturePreparers(
prepareForApexTest,
java.PrepareForTestWithJavaSdkLibraryFiles,
@@ -163,6 +164,7 @@
}
func TestNonUpdatableApexDepsContainers(t *testing.T) {
+ t.Parallel()
result := android.GroupFixturePreparers(
prepareForApexTest,
java.PrepareForTestWithJavaSdkLibraryFiles,
@@ -277,6 +279,7 @@
}
func TestUpdatableAndNonUpdatableApexesIdenticalMinSdkVersion(t *testing.T) {
+ t.Parallel()
result := android.GroupFixturePreparers(
prepareForApexTest,
java.PrepareForTestWithJavaSdkLibraryFiles,