mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-11-21 23:46:18 -05:00
Adding __json__ to Downloader for sending them to the FE. Hiding ChannelDownloader because it will be handled specifically.
This commit is contained in:
parent
047b507119
commit
e3c57ef674
3 changed files with 14 additions and 7 deletions
|
|
@ -50,6 +50,7 @@ class ChannelDownloader(Downloader, ABC):
|
|||
"""
|
||||
name = 'video_channel'
|
||||
pretty_name = 'Video Channel'
|
||||
listable = False
|
||||
|
||||
def __repr__(self):
|
||||
return f'<ChannelDownloader name={self.name}>'
|
||||
|
|
|
|||
|
|
@ -426,3 +426,11 @@ def test_selected_downloader(test_session, video_download_manager):
|
|||
mock_do_download.assert_called_once()
|
||||
|
||||
check_attempts(3)
|
||||
|
||||
|
||||
def test_channel_downloader_hidden(video_download_manager):
|
||||
"""
|
||||
ChannelDownloader should not be presented to the User.
|
||||
"""
|
||||
downloaders = video_download_manager.list_downloaders()
|
||||
assert downloaders == [(dict(name='video', pretty_name='Videos')), ]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue