def __init__(self, **kwargs): BaseMarionetteTestRunner.__init__(self, **kwargs) if not self.server_root: self.server_root = external_media_tests.resources # pick up prefs from marionette_driver.goannainstance.DesktopInstance self.app = 'fxdesktop' self.test_handlers = [MediaTestCase] # Used in HTML report (--log-html) def gather_media_debug(test, status): rv = {} marionette = test._marionette_weakref() if marionette.session is not None: try: with marionette.using_context(marionette.CONTEXT_CHROME): debug_lines = marionette.execute_script(debug_script) if debug_lines: name = 'mozMediaSourceObject.mozDebugReaderData' rv[name] = '\n'.join(debug_lines) else: logger = mozlog.get_default_logger() logger.info('No data available about ' 'mozMediaSourceObject') except: logger = mozlog.get_default_logger() logger.warning('Failed to gather test failure media debug', exc_info=True) return rv self.result_callbacks.append(gather_media_debug)
def __init__(self, **kwargs): BaseMarionetteTestRunner.__init__(self, **kwargs) if not self.server_root: self.server_root = external_media_tests.resources # pick up prefs from marionette_driver.geckoinstance.DesktopInstance self.app = 'fxdesktop' self.test_handlers = [MediaTestCase] # Used in HTML report (--log-html) def gather_media_debug(test, status): rv = {} marionette = test._marionette_weakref() if marionette.session is not None: try: with marionette.using_context(marionette.CONTEXT_CHROME): debug_lines = marionette.execute_script(debug_script) if debug_lines: name = 'mozMediaSourceObject.mozDebugReaderData' rv[name] = '\n'.join(debug_lines) else: logger = mozlog.get_default_logger() logger.info('No data available about ' 'mozMediaSourceObject') except: logger = mozlog.get_default_logger() logger.warning('Failed to gather test failure media debug', exc_info=True) return rv self.result_callbacks.append(gather_media_debug)
def __init__(self, **kwargs): BaseMarionetteTestRunner.__init__(self, **kwargs) self.test_handlers = [MarionetteTestCase]