summaryrefslogtreecommitdiff
path: root/python/test.go
diff options
context:
space:
mode:
Diffstat (limited to 'python/test.go')
-rw-r--r--python/test.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/python/test.go b/python/test.go
index cd7c73b5a..41c5538d5 100644
--- a/python/test.go
+++ b/python/test.go
@@ -188,8 +188,6 @@ func (p *PythonTestModule) GenerateAndroidBuildActions(ctx android.ModuleContext
panic(fmt.Errorf("unknown python test runner '%s', should be 'tradefed' or 'mobly'", runner))
}
- p.installedDest = ctx.InstallFile(installDir(ctx, "nativetest", "nativetest64", ctx.ModuleName()), p.installSource.Base(), p.installSource)
-
for _, dataSrcPath := range android.PathsForModuleSrc(ctx, p.testProperties.Data) {
p.data = append(p.data, android.DataPath{SrcPath: dataSrcPath})
}
@@ -206,6 +204,11 @@ func (p *PythonTestModule) GenerateAndroidBuildActions(ctx android.ModuleContext
p.data = append(p.data, android.DataPath{SrcPath: javaDataSrcPath})
}
}
+
+ installDir := installDir(ctx, "nativetest", "nativetest64", ctx.ModuleName())
+ installedData := ctx.InstallTestData(installDir, p.data)
+ p.installedDest = ctx.InstallFile(installDir, p.installSource.Base(), p.installSource, installedData...)
+
ctx.SetProvider(testing.TestModuleProviderKey, testing.TestModuleProviderData{})
}
@@ -227,8 +230,6 @@ func (p *PythonTestModule) AndroidMkEntries() []android.AndroidMkEntries {
entries.SetBoolIfTrue("LOCAL_DISABLE_AUTO_GENERATE_TEST_CONFIG", !BoolDefault(p.binaryProperties.Auto_gen_config, true))
- entries.AddStrings("LOCAL_TEST_DATA", android.AndroidMkDataPaths(p.data)...)
-
p.testProperties.Test_options.SetAndroidMkEntries(entries)
})