aboutsummaryrefslogtreecommitdiffstats
path: root/python/python_test.go
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2017-06-23 15:06:31 -0700
committerColin Cross <ccross@android.com>2017-06-30 21:08:36 +0000
commit36242850fdad11b4e6fbe061ef30f62e7e8c08d8 (patch)
treea3ca380533afd39e733c658560f87effb1ee0a46 /python/python_test.go
parent48173891485a22c9cab0e48f90a3a23be212f44a (diff)
downloadbuild_soong-36242850fdad11b4e6fbe061ef30f62e7e8c08d8.tar.gz
build_soong-36242850fdad11b4e6fbe061ef30f62e7e8c08d8.tar.bz2
build_soong-36242850fdad11b4e6fbe061ef30f62e7e8c08d8.zip
Refactor factories
Change module factories from returning a blueprint.Module and a list of property structs to returning an android.Module, which holds the list of property structs. Test: build.ninja identical except for Factory: comment lines Change-Id: Ica1d823f009db812c518f271a386fbff39c9766f
Diffstat (limited to 'python/python_test.go')
-rw-r--r--python/python_test.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/python/python_test.go b/python/python_test.go
index bb407e46..57aaa344 100644
--- a/python/python_test.go
+++ b/python/python_test.go
@@ -313,8 +313,10 @@ func TestPythonModule(t *testing.T) {
t.Run(d.desc, func(t *testing.T) {
ctx := blueprint.NewContext()
android.RegisterTestMutators(ctx)
- ctx.RegisterModuleType("python_library_host", PythonLibraryHostFactory)
- ctx.RegisterModuleType("python_binary_host", PythonBinaryHostFactory)
+ ctx.RegisterModuleType("python_library_host",
+ android.ModuleFactoryAdaptor(PythonLibraryHostFactory))
+ ctx.RegisterModuleType("python_binary_host",
+ android.ModuleFactoryAdaptor(PythonBinaryHostFactory))
ctx.MockFileSystem(d.mockFiles)
_, testErrs := ctx.ParseBlueprintsFiles(bpFile)
fail(t, testErrs)