Merge "Fix single value variable inheritance order"

This commit is contained in:
Treehugger Robot
2022-04-05 21:34:26 +00:00
committed by Gerrit Code Review
5 changed files with 21 additions and 7 deletions

View File

@@ -19,3 +19,5 @@ def init(g, handle):
cfg["PRODUCT_CHARACTERISTICS"] = "tablet"
cfg["PRODUCT_DEFAULT_DEV_CERTIFICATE"] = "vendor/myvendor/certs/devkeys/devkey"
cfg.setdefault("PRODUCT_PACKAGES", [])
cfg["PRODUCT_PACKAGES"] += ["bar"]

View File

@@ -18,3 +18,5 @@ def init(g, handle):
cfg = rblf.cfg(handle)
cfg["PRODUCT_CHARACTERISTICS"] = "nosdcard"
cfg.setdefault("PRODUCT_PACKAGES", [])
cfg["PRODUCT_PACKAGES"] += ["foo"]

View File

@@ -18,7 +18,7 @@ load(":inherit2.rbc", _inherit2_init = "init")
def init(g, handle):
cfg = rblf.cfg(handle)
rblf.inherit(handle, "test/inherit1", _inherit1_init)
rblf.inherit(handle, "test/inherit2", _inherit2_init)
rblf.inherit(handle, "test/inherit1", _inherit1_init)
cfg["PRODUCT_DEFAULT_DEV_CERTIFICATE"] = ""

View File

@@ -25,3 +25,4 @@ def test():
(globals, config, globals_base) = rblf.product_configuration("test/device", init, input_variables_init)
assert_eq("tablet", config["PRODUCT_CHARACTERISTICS"])
assert_eq("vendor/myvendor/certs/devkeys/devkey", config["PRODUCT_DEFAULT_DEV_CERTIFICATE"])
assert_eq(["foo", "bar"], config["PRODUCT_PACKAGES"])