aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2021-07-20 11:58:41 -0700
committerColin Cross <ccross@android.com>2021-07-20 11:58:41 -0700
commit63aebf250bc079f991a6b00b995287bb6649c78e (patch)
tree375d35f0bb23d5e71eafb9d1657b2940b598311a
parent08c59177ebcf25c9e36d4039d0dd00b91335660e (diff)
downloadplatform_test_app_compat_csuite-63aebf250bc079f991a6b00b995287bb6649c78e.tar.gz
platform_test_app_compat_csuite-63aebf250bc079f991a6b00b995287bb6649c78e.tar.bz2
platform_test_app_compat_csuite-63aebf250bc079f991a6b00b995287bb6649c78e.zip
Use config.BuildOS instead of android.BuildOs
android.BuildOs is being replaced with config.BuildOS so that it can vary based on the product configuration. Bug: 190084016 Test: m checkbuild Change-Id: Ia1de8034ed3db152befe2f2b61650c8375e6f6ca
-rw-r--r--tools/csuite_test/csuite_test_test.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/csuite_test/csuite_test_test.go b/tools/csuite_test/csuite_test_test.go
index daf07b0..ac04705 100644
--- a/tools/csuite_test/csuite_test_test.go
+++ b/tools/csuite_test/csuite_test_test.go
@@ -98,7 +98,7 @@ func TestValidBpMissingPlanIncludeGeneratesPlanXmlWithoutPlaceholders(t *testing
parseBpAndBuild(t, ctx, config)
- module := ctx.ModuleForTests("plan_name", android.BuildOs.String()+"_common")
+ module := ctx.ModuleForTests("plan_name", config.BuildOS.String()+"_common")
content := android.ContentFromFileRuleForTests(t, module.Output("config/plan_name.xml"))
if strings.Contains(content, "{") || strings.Contains(content, "}") {
t.Errorf("The generated plan name contains a placeholder: %s", content)
@@ -115,7 +115,7 @@ func TestGeneratedTestPlanContainsPlanName(t *testing.T) {
parseBpAndBuild(t, ctx, config)
- module := ctx.ModuleForTests("plan_name", android.BuildOs.String()+"_common")
+ module := ctx.ModuleForTests("plan_name", config.BuildOS.String()+"_common")
content := android.ContentFromFileRuleForTests(t, module.Output("config/plan_name.xml"))
if !strings.Contains(content, "plan_name") {
t.Errorf("The plan name is missing from the generated plan: %s", content)
@@ -132,7 +132,7 @@ func TestGeneratedTestPlanContainsTemplatePath(t *testing.T) {
parseBpAndBuild(t, ctx, config)
- module := ctx.ModuleForTests("plan_name", android.BuildOs.String()+"_common")
+ module := ctx.ModuleForTests("plan_name", config.BuildOS.String()+"_common")
content := android.ContentFromFileRuleForTests(t, module.Output("config/plan_name.xml"))
if !strings.Contains(content, "config/plan_name.xml.template") {
t.Errorf("The template path is missing from the generated plan: %s", content)
@@ -149,7 +149,7 @@ func TestTemplateFileCopyRuleExists(t *testing.T) {
parseBpAndBuild(t, ctx, config)
- params := ctx.ModuleForTests("plan_name", android.BuildOs.String()+"_common").Rule("CSuite")
+ params := ctx.ModuleForTests("plan_name", config.BuildOS.String()+"_common").Rule("CSuite")
assertFileCopyRuleExists(t, params, "test_config.xml.template", "config/plan_name.xml.template")
}
@@ -164,7 +164,7 @@ func TestGeneratedTestPlanContainsPlanInclude(t *testing.T) {
parseBpAndBuild(t, ctx, config)
- module := ctx.ModuleForTests("plan_name", android.BuildOs.String()+"_common")
+ module := ctx.ModuleForTests("plan_name", config.BuildOS.String()+"_common")
content := android.ContentFromFileRuleForTests(t, module.Output("config/plan_name.xml"))
if !strings.Contains(content, `"includes/plan_name.xml"`) {
t.Errorf("The plan include path is missing from the generated plan: %s", content)
@@ -182,7 +182,7 @@ func TestPlanIncludeFileCopyRuleExists(t *testing.T) {
parseBpAndBuild(t, ctx, config)
- params := ctx.ModuleForTests("plan_name", android.BuildOs.String()+"_common").Rule("CSuite")
+ params := ctx.ModuleForTests("plan_name", config.BuildOS.String()+"_common").Rule("CSuite")
assertFileCopyRuleExists(t, params, "include.xml", "config/includes/plan_name.xml")
}