summaryrefslogtreecommitdiff
path: root/java/java_test.go
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2019-04-16 14:43:28 -0700
committerColin Cross <ccross@android.com>2019-04-16 21:46:28 +0000
commitf8b860a0fb98448dd44db835d5f146e8a50e5ef5 (patch)
treedd9e592e116916035dcfc5b84552a5ffef5139cf /java/java_test.go
parent819635624843ae286cefae6a9a89d3d90ed61cd8 (diff)
Use LoadHook to create modules in java_sdk_library
Creating new modules in a mutator is dangerous, as other mutators that need to see the new modules may already have run, in this case the prebuilts mutator. Move SdkLibraryMutator to a LoadHook instead. Also moves registering the LoadHook mutator to testing.go so it is registered for all tests. Test: m checkbuild Change-Id: I08bd76a0e6205d2ca27861058067a1562c339eed
Diffstat (limited to 'java/java_test.go')
-rw-r--r--java/java_test.go1
1 files changed, 0 insertions, 1 deletions
diff --git a/java/java_test.go b/java/java_test.go
index 3ae993d26..89f871cb1 100644
--- a/java/java_test.go
+++ b/java/java_test.go
@@ -94,7 +94,6 @@ func testContext(config android.Config, bp string,
ctx.PreArchMutators(android.RegisterOverridePreArchMutators)
ctx.PreArchMutators(func(ctx android.RegisterMutatorsContext) {
ctx.TopDown("prebuilt_apis", PrebuiltApisMutator).Parallel()
- ctx.TopDown("java_sdk_library", SdkLibraryMutator).Parallel()
})
ctx.RegisterPreSingletonType("overlay", android.SingletonFactoryAdaptor(OverlaySingletonFactory))
ctx.RegisterPreSingletonType("sdk", android.SingletonFactoryAdaptor(sdkSingletonFactory))