Bug 787203 - [mozrunner] Update `disconnected` when cleaning up after emulator shutdown; r?ahal draft
authorMaja Frydrychowicz <mjzffr@gmail.com>
Wed, 29 Jun 2016 00:44:34 -0400
changeset 384161 0fab90810807c40ecf7765209dd3e2bbabb499dd
parent 384160 c5510f73280f13e332696e919a072e18c29599ee
child 384162 5740f34d24d9af7ea531de2d8af2f63dad751cdf
push id22185
push usermjzffr@gmail.com
push dateTue, 05 Jul 2016 18:12:09 +0000
reviewersahal
bugs787203
milestone50.0a1
Bug 787203 - [mozrunner] Update `disconnected` when cleaning up after emulator shutdown; r?ahal Allows Marionette client's FennecInstance to clean up properly MozReview-Commit-ID: BWuNh5cq3ZD
testing/mozbase/mozrunner/mozrunner/devices/emulator.py
--- a/testing/mozbase/mozrunner/mozrunner/devices/emulator.py
+++ b/testing/mozbase/mozrunner/mozrunner/devices/emulator.py
@@ -155,16 +155,17 @@ class BaseEmulator(Device):
     def cleanup(self):
         """
         Cleans up and kills the emulator, if it was started by mozrunner.
         """
         super(BaseEmulator, self).cleanup()
         if self.proc:
             self.proc.kill()
             self.proc = None
+            self.connected = False
 
         # Remove temporary files
         shutil.rmtree(self.tmpdir)
 
     def _get_telnet_response(self, command=None):
         output = []
         assert self.telnet
         if command is not None: