fix tests
This commit is contained in:
parent
01bc12acab
commit
f741649001
3 changed files with 11 additions and 7 deletions
|
|
@ -10,9 +10,7 @@ TBaseEntry = TypeVar("TBaseEntry", bound=BaseEntry)
|
||||||
|
|
||||||
|
|
||||||
class EntryParent(BaseEntry):
|
class EntryParent(BaseEntry):
|
||||||
def __init__(
|
def __init__(self, entry_dict: Dict, working_directory: str):
|
||||||
self, entry_dict: Dict, working_directory: str
|
|
||||||
):
|
|
||||||
super().__init__(entry_dict=entry_dict, working_directory=working_directory)
|
super().__init__(entry_dict=entry_dict, working_directory=working_directory)
|
||||||
self.child_entries: List["EntryParent"] = []
|
self.child_entries: List["EntryParent"] = []
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -598,7 +598,7 @@ class DownloadArchiver:
|
||||||
"""
|
"""
|
||||||
|
|
||||||
def __init__(self, enhanced_download_archive: EnhancedDownloadArchive):
|
def __init__(self, enhanced_download_archive: EnhancedDownloadArchive):
|
||||||
self.__enhanced_download_archive = enhanced_download_archive
|
self._enhanced_download_archive = enhanced_download_archive
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def working_directory(self) -> str:
|
def working_directory(self) -> str:
|
||||||
|
|
@ -607,7 +607,7 @@ class DownloadArchiver:
|
||||||
-------
|
-------
|
||||||
Path to the working directory
|
Path to the working directory
|
||||||
"""
|
"""
|
||||||
return self.__enhanced_download_archive.working_directory
|
return self._enhanced_download_archive.working_directory
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def is_dry_run(self) -> bool:
|
def is_dry_run(self) -> bool:
|
||||||
|
|
@ -616,7 +616,7 @@ class DownloadArchiver:
|
||||||
-------
|
-------
|
||||||
True if this session is a dry-run. False otherwise.
|
True if this session is a dry-run. False otherwise.
|
||||||
"""
|
"""
|
||||||
return self.__enhanced_download_archive.is_dry_run
|
return self._enhanced_download_archive.is_dry_run
|
||||||
|
|
||||||
def save_file(
|
def save_file(
|
||||||
self,
|
self,
|
||||||
|
|
@ -640,7 +640,7 @@ class DownloadArchiver:
|
||||||
entry
|
entry
|
||||||
Optional. Entry that the file belongs to
|
Optional. Entry that the file belongs to
|
||||||
"""
|
"""
|
||||||
self.__enhanced_download_archive.save_file_to_output_directory(
|
self._enhanced_download_archive.save_file_to_output_directory(
|
||||||
file_name=file_name,
|
file_name=file_name,
|
||||||
file_metadata=file_metadata,
|
file_metadata=file_metadata,
|
||||||
output_file_name=output_file_name,
|
output_file_name=output_file_name,
|
||||||
|
|
|
||||||
|
|
@ -85,6 +85,12 @@ def mock_entry_to_dict(
|
||||||
"thumbnail_ext": thumbnail_ext,
|
"thumbnail_ext": thumbnail_ext,
|
||||||
"info_json_ext": "info.json",
|
"info_json_ext": "info.json",
|
||||||
"webpage_url": webpage_url,
|
"webpage_url": webpage_url,
|
||||||
|
"playlist": "entry {title}",
|
||||||
|
"playlist_sanitized": "entry {title}",
|
||||||
|
"playlist_index": 1,
|
||||||
|
"playlist_index_padded": "01",
|
||||||
|
"playlist_count": 1,
|
||||||
|
"playlist_max_upload_year": 2021,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue