Move autogenerated test config into Soong am: 303e21f695
am: f83e82933e
am: 16a1d89a2a
Change-Id: Ib3fadbfbaaa90dcc08d2539290965733104fcfc1
This commit is contained in:
10
java/java.go
10
java/java.go
@@ -29,6 +29,7 @@ import (
|
||||
|
||||
"android/soong/android"
|
||||
"android/soong/java/config"
|
||||
"android/soong/tradefed"
|
||||
)
|
||||
|
||||
func init() {
|
||||
@@ -1356,6 +1357,14 @@ type Test struct {
|
||||
Library
|
||||
|
||||
testProperties testProperties
|
||||
|
||||
testConfig android.Path
|
||||
}
|
||||
|
||||
func (j *Test) GenerateAndroidBuildActions(ctx android.ModuleContext) {
|
||||
j.testConfig = tradefed.AutoGenJavaTestConfig(ctx, j.testProperties.Test_config)
|
||||
|
||||
j.Library.GenerateAndroidBuildActions(ctx)
|
||||
}
|
||||
|
||||
func (j *Test) DepsMutator(ctx android.BottomUpMutatorContext) {
|
||||
@@ -1363,6 +1372,7 @@ func (j *Test) DepsMutator(ctx android.BottomUpMutatorContext) {
|
||||
if BoolDefault(j.testProperties.Junit, true) {
|
||||
ctx.AddDependency(ctx.Module(), staticLibTag, "junit")
|
||||
}
|
||||
android.ExtractSourceDeps(ctx, j.testProperties.Test_config)
|
||||
}
|
||||
|
||||
func TestFactory() android.Module {
|
||||
|
Reference in New Issue
Block a user