return True return False def __play_action(params, processed): """ Play an item :param params: Route paramters :type params: dict :param processed: Other route already matched :type processed: bool :returns: bool -- Route matched """ video_id = params.get('video_id') if video_id is not None and processed is False: CONTENT_LOADER.play(video_id=video_id) return True return False if __name__ == '__main__': # Load addon data & start plugin ADDON = UTILS.get_addon() ADDON_DATA = UTILS.get_addon_data() UTILS.log('Started (Version {0})'.format(ADDON_DATA.get('version'))) # Call the router function and pass # the plugin call parameters to it. # We use string slicing to trim the # leading '?' from the plugin call paramstring router(argv[2][1:])
def test_get_addon(self): """ADD ME""" utils = Utils(kodi_base_url='/foo/', constants=Constants()) self.assertIn( container=str(utils.get_addon()), member='xbmcaddon.Addon')