def SetUp(self): """Run once before all tests are run.""" Forwarder.KillDevice(self.adb, self.tool) self.InstallTestPackage() if self._push_deps: logging.info('Pushing data deps to device.') self.PushDataDeps() else: logging.warning('Skipping pushing data deps to device.')
def ShutdownHelperToolsForTestSuite(self): """Shuts down the server and the forwarder.""" # Forwarders should be killed before the actual servers they're forwarding # to as they are clients potentially with open connections and to allow for # proper hand-shake/shutdown. Forwarder.KillDevice(self.adb, self.tool) if self._http_server: self._http_server.ShutdownHttpServer() if self._spawning_server: self._spawning_server.Stop() self.flags.Restore()
def SetUp(self): """Run once before all tests are run.""" Forwarder.KillDevice(self.adb, self.tool) self.InstallTestPackage() push_size_before = self.adb.GetPushSizeInfo() if self._push_deps: logging.warning('Pushing data files to device.') self.PushDataDeps() push_size_after = self.adb.GetPushSizeInfo() logging.warning( 'Total data: %0.3fMB' % ((push_size_after[0] - push_size_before[0]) / float(2**20))) logging.warning( 'Total data transferred: %0.3fMB' % ((push_size_after[1] - push_size_before[1]) / float(2**20))) else: logging.warning('Skipping pushing data to device.')
def SetUp(self): """Run once before all tests are run.""" Forwarder.KillDevice(self.adb, self.tool)
def SetUp(self): """Called before tests run.""" Forwarder.KillDevice(self.adb, self.tool)