当前位置: 首页>>代码示例>>Python>>正文


Python BlipTVNavigation.executeAction方法代码示例

本文整理汇总了Python中BlipTVNavigation.BlipTVNavigation.executeAction方法的典型用法代码示例。如果您正苦于以下问题:Python BlipTVNavigation.executeAction方法的具体用法?Python BlipTVNavigation.executeAction怎么用?Python BlipTVNavigation.executeAction使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BlipTVNavigation.BlipTVNavigation的用法示例。


在下文中一共展示了BlipTVNavigation.executeAction方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: test_executeAction_should_call_listMenu_if_action_is_edit_search

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_listMenu_if_action_is_edit_search(self):
        navigation = BlipTVNavigation()
        navigation.listMenu = Mock()

        navigation.executeAction({"action": "edit_search"})

        navigation.listMenu.assert_called_with({"action": "edit_search"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:9,代码来源:TestBlipTVNavigation.py

示例2: test_executeAction_should_call_storage_editStoredSearch_if_action_is_edit_search

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_storage_editStoredSearch_if_action_is_edit_search(self):
        navigation = BlipTVNavigation()
        navigation.listMenu = Mock()

        navigation.executeAction({"action": "edit_search"})

        sys.modules["__main__"].storage.editStoredSearch.assert_called_with({"action": "edit_search"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:9,代码来源:TestBlipTVNavigation.py

示例3: test_executeAction_should_call_addToFavorites_if_action_is_add_favorite

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_addToFavorites_if_action_is_add_favorite(self):
        sys.modules["__main__"].scraper.addShowToMyFavorites = Mock()
        navigation = BlipTVNavigation()
        navigation.addToFavorites = Mock()

        navigation.executeAction({"action": "add_favorite"})

        sys.modules["__main__"].scraper.addShowToMyFavorites.assert_called_with({"action": "add_favorite"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:10,代码来源:TestBlipTVNavigation.py

示例4: test_executeAction_should_open_settings_if_action_is_settings

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_open_settings_if_action_is_settings(self):
        sys.modules["__main__"].storage.deleteFromMyFavoriteShows = Mock()
        navigation = BlipTVNavigation()
        navigation.removeFromFavorites = Mock()

        navigation.executeAction({"action": "settings"})

        sys.modules["__main__"].settings.openSettings.assert_called_with()
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:10,代码来源:TestBlipTVNavigation.py

示例5: test_executeAction_should_call_removeFromFavorites_if_action_is_remove_favorite

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_removeFromFavorites_if_action_is_remove_favorite(self):
        sys.modules["__main__"].storage.deleteFromMyFavoriteShows = Mock()
        navigation = BlipTVNavigation()
        navigation.removeFromFavorites = Mock()

        navigation.executeAction({"action": "delete_favorite"})

        sys.modules["__main__"].storage.deleteFromMyFavoriteShows.assert_called_with({"action": "delete_favorite"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:10,代码来源:TestBlipTVNavigation.py

示例6: test_executeAction_should_call_downloader_downloadVideo_if_action_is_download

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_downloader_downloadVideo_if_action_is_download(self):
        sys.modules["__main__"].player.getVideoObject = Mock()
        sys.modules["__main__"].player.getVideoObject.return_value = {"videoid": "video1", "video_url": "Mock url", "Title": "Mock Title"}
        sys.modules["__main__"].settings.getSetting.return_value = "some_path"

        navigation = BlipTVNavigation()

        navigation.executeAction({"action": "download"})

        sys.modules["__main__"].downloader.download.assert_called_with("Mock Title-[video1].mp4", {"action": "download", "url": "Mock url", "download_path": "some_path", "useragent": "curl/7.22.0 (x86_64-pc-linux-gnu) libcurl/7.22.0 OpenSSL/1.0.1 zlib/1.2.3.4 libidn/1.23 librtmp/2.3"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:12,代码来源:TestBlipTVNavigation.py

示例7: ttest_executeAction_should_call_playlist_playAll_if_action_is_play_all

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def ttest_executeAction_should_call_playlist_playAll_if_action_is_play_all(self):
        navigation = BlipTVNavigation()

        navigation.executeAction({"action": "play_all"})

        sys.modules["__main__"].playlist.playAll.assert_called_with({"action": "play_all"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:8,代码来源:TestBlipTVNavigation.py

示例8: ttest_executeAction_should_call_playlist_queueVideo_if_action_is_queue_video

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def ttest_executeAction_should_call_playlist_queueVideo_if_action_is_queue_video(self):
        navigation = BlipTVNavigation()

        navigation.executeAction({"action": "queue_video"})

        sys.modules["__main__"].playlist.queueVideo.assert_called_with({"action": "queue_video"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:8,代码来源:TestBlipTVNavigation.py

示例9: test_executeAction_should_call_player_playVideo_if_action_is_play_video

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_player_playVideo_if_action_is_play_video(self):
        navigation = BlipTVNavigation()

        navigation.executeAction({"action": "play_video"})

        sys.modules["__main__"].player.playVideo.assert_called_with({"action": "play_video"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:8,代码来源:TestBlipTVNavigation.py

示例10: test_executeAction_should_call_storage_deleteStoredSearch_if_action_is_delete_search

# 需要导入模块: from BlipTVNavigation import BlipTVNavigation [as 别名]
# 或者: from BlipTVNavigation.BlipTVNavigation import executeAction [as 别名]
    def test_executeAction_should_call_storage_deleteStoredSearch_if_action_is_delete_search(self):
        navigation = BlipTVNavigation()

        navigation.executeAction({"action": "delete_search"})

        sys.modules["__main__"].storage.deleteStoredSearch.assert_called_with({"action": "delete_search"})
开发者ID:HenrikDK,项目名称:bliptv-xbmc-plugin,代码行数:8,代码来源:TestBlipTVNavigation.py


注:本文中的BlipTVNavigation.BlipTVNavigation.executeAction方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。