Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ea75976e authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Cert: Suppress expected errors with pulling files"

parents cac2cb82 8e335df8
Loading
Loading
Loading
Loading
+21 −6
Original line number Diff line number Diff line
@@ -304,12 +304,27 @@ class GdAndroidDevice(GdDeviceBase):
            logging.error("logcat_process %s_%s stopped with code: %d" % (self.label, self.serial_number, return_code))
        self.logcat_logger.stop()
        self.cleanup_port_forwarding()
        self.adb.pull("/data/misc/bluetooth/logs/btsnoop_hci.log %s" % os.path.join(self.log_path_base,
                                                                                    "%s_btsnoop_hci.log" % self.label))
        try:
            self.adb.pull("/data/misc/bluetooth/logs/btsnoop_hci.log %s" % os.path.join(
                self.log_path_base, "%s_btsnoop_hci.log" % self.label))
        except AdbError as error:
            # Some tests have no snoop logs, and that's OK
            if "No such file or directory" not in str(error):
                logging.error("While trying to pull log files" + str(error))
        try:
            self.adb.pull("/data/misc/bluedroid/bt_config.conf %s" % os.path.join(self.log_path_base,
                                                                                  "%s_bt_config.conf" % self.label))
        self.adb.pull(
            "/data/misc/bluedroid/bt_config.bak %s" % os.path.join(self.log_path_base, "%s_bt_config.bak" % self.label))
        except AdbError as error:
            # Some tests have no config file, and that's OK
            if "No such file or directory" not in str(error):
                logging.error("While trying to pull log files" + str(error))
        try:
            self.adb.pull("/data/misc/bluedroid/bt_config.bak %s" % os.path.join(self.log_path_base,
                                                                                 "%s_bt_config.bak" % self.label))
        except AdbError as error:
            # Some tests have no config.bak file, and that's OK
            if "No such file or directory" not in str(error):
                logging.error("While trying to pull log files" + str(error))

    def cleanup_port_forwarding(self):
        try: