From 36c45bba5481e6ff52c1489ef364bc1a90a00bc1 Mon Sep 17 00:00:00 2001 From: Geoff Brown Date: Fri, 21 Sep 2018 13:23:48 -0600 Subject: [PATCH] Bug 1492632 - Ensure correct installation requirements for Android per-test suites; r=bc --- testing/mozharness/scripts/android_emulator_unittest.py | 5 +++-- testing/mozharness/scripts/android_hardware_unittest.py | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/testing/mozharness/scripts/android_emulator_unittest.py b/testing/mozharness/scripts/android_emulator_unittest.py index a201c60a1ec5..2ebec33c38de 100644 --- a/testing/mozharness/scripts/android_emulator_unittest.py +++ b/testing/mozharness/scripts/android_emulator_unittest.py @@ -651,12 +651,13 @@ class AndroidEmulatorTest(TestingMixin, BaseScript, MozbaseMixin, CodeCoverageMi def pre_create_virtualenv(self, action): dirs = self.query_abs_dirs() requirements = None - if self.test_suite == 'mochitest-media': + suites = self._query_suites() + if ('mochitest-media', 'mochitest-media') in suites: # mochitest-media is the only thing that needs this requirements = os.path.join(dirs['abs_mochitest_dir'], 'websocketprocessbridge', 'websocketprocessbridge_requirements.txt') - elif self.test_suite == 'marionette': + elif ('marionette', 'marionette') in suites: requirements = os.path.join(dirs['abs_test_install_dir'], 'config', 'marionette_requirements.txt') if requirements: diff --git a/testing/mozharness/scripts/android_hardware_unittest.py b/testing/mozharness/scripts/android_hardware_unittest.py index 1daf5f944463..f68dbc297789 100644 --- a/testing/mozharness/scripts/android_hardware_unittest.py +++ b/testing/mozharness/scripts/android_hardware_unittest.py @@ -169,12 +169,13 @@ class AndroidHardwareTest(TestingMixin, BaseScript, MozbaseMixin, def _pre_create_virtualenv(self, action): dirs = self.query_abs_dirs() requirements = None - if self.test_suite == 'mochitest-media': + suites = self._query_suites() + if ('mochitest-media', 'mochitest-media') in suites: # mochitest-media is the only thing that needs this requirements = os.path.join(dirs['abs_mochitest_dir'], 'websocketprocessbridge', 'websocketprocessbridge_requirements.txt') - elif self.test_suite == 'marionette': + elif ('marionette', 'marionette') in suites: requirements = os.path.join(dirs['abs_test_install_dir'], 'config', 'marionette_requirements.txt') if requirements: