Add qt targets to cros_mark_android_as_stable
Cq-Depend: chrome-internal:1219904,chrome-internal:1231235
BUG=b:129410042
TEST=./cros_mark_android_as_stable_unittest
cros_mark_android_as_stable --android_build_branch git_qt-arc-dev
--android_package android-container-qt
Change-Id: I7ec4a0ae1219c867aef0fd67e74e9136c28a1eaa
Reviewed-on: https://chromium-review.googlesource.com/1590465
Commit-Ready: Richard Fung <richardfung@google.com>
Tested-by: Richard Fung <richardfung@google.com>
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Reviewed-by: Bernie Thompson <bhthompson@chromium.org>
Reviewed-by: Ben Lin <linben@chromium.org>
diff --git a/scripts/cros_mark_android_as_stable.py b/scripts/cros_mark_android_as_stable.py
index b490b07..9816893 100644
--- a/scripts/cros_mark_android_as_stable.py
+++ b/scripts/cros_mark_android_as_stable.py
@@ -454,6 +454,8 @@
return constants.ANDROID_NYC_BUILD_TARGETS
elif build_branch == constants.ANDROID_PI_BUILD_BRANCH:
return constants.ANDROID_PI_BUILD_TARGETS
+ elif build_branch == constants.ANDROID_QT_BUILD_BRANCH:
+ return constants.ANDROID_QT_BUILD_TARGETS
elif build_branch == constants.ANDROID_VMPI_BUILD_BRANCH:
return constants.ANDROID_VMPI_BUILD_TARGETS
else:
diff --git a/scripts/cros_mark_android_as_stable_unittest.py b/scripts/cros_mark_android_as_stable_unittest.py
index 766d30f..3daa8e0 100644
--- a/scripts/cros_mark_android_as_stable_unittest.py
+++ b/scripts/cros_mark_android_as_stable_unittest.py
@@ -514,6 +514,10 @@
for t in cros_mark_android_as_stable.MakeBuildTargetDict(
constants.ANDROID_PI_BUILD_BRANCH).keys():
self.assertTrue(t in acls)
+ # Test that all QT targets have their ACLS set.
+ for t in cros_mark_android_as_stable.MakeBuildTargetDict(
+ constants.ANDROID_QT_BUILD_BRANCH).keys():
+ self.assertTrue(t in acls)
# Test that all VMPI targets have their ACLS set.
for t in cros_mark_android_as_stable.MakeBuildTargetDict(
constants.ANDROID_VMPI_BUILD_BRANCH).keys():
@@ -567,6 +571,22 @@
self.assertEquals(targets[target],
constants.ANDROID_PI_BUILD_TARGETS[target])
+ def testMakeBuildTargetDictQT(self):
+ """Test generation of QT build target dictionary.
+
+ If the number of targets is correct and QT-specific targets are
+ present, then the dictionary is correct.
+ """
+ targets = cros_mark_android_as_stable.MakeBuildTargetDict(
+ constants.ANDROID_QT_BUILD_BRANCH)
+ # Test the number of targets.
+ self.assertEquals(len(targets),
+ len(constants.ANDROID_QT_BUILD_TARGETS))
+ # Test that all QT-specific targets are in the dictionary.
+ for target in constants.ANDROID_QT_BUILD_TARGETS:
+ self.assertEquals(targets[target],
+ constants.ANDROID_QT_BUILD_TARGETS[target])
+
def testMakeBuildTargetDictVMPI(self):
"""Test generation of VMPI build target dictionary.