fix tests

This commit is contained in:
Jesse Bannon 2022-09-14 12:16:20 -07:00
parent 01bc12acab
commit f741649001
3 changed files with 11 additions and 7 deletions

View file

@ -10,9 +10,7 @@ TBaseEntry = TypeVar("TBaseEntry", bound=BaseEntry)
class EntryParent(BaseEntry):
def __init__(
self, entry_dict: Dict, working_directory: str
):
def __init__(self, entry_dict: Dict, working_directory: str):
super().__init__(entry_dict=entry_dict, working_directory=working_directory)
self.child_entries: List["EntryParent"] = []

View file

@ -598,7 +598,7 @@ class DownloadArchiver:
"""
def __init__(self, enhanced_download_archive: EnhancedDownloadArchive):
self.__enhanced_download_archive = enhanced_download_archive
self._enhanced_download_archive = enhanced_download_archive
@property
def working_directory(self) -> str:
@ -607,7 +607,7 @@ class DownloadArchiver:
-------
Path to the working directory
"""
return self.__enhanced_download_archive.working_directory
return self._enhanced_download_archive.working_directory
@property
def is_dry_run(self) -> bool:
@ -616,7 +616,7 @@ class DownloadArchiver:
-------
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(
self,
@ -640,7 +640,7 @@ class DownloadArchiver:
entry
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_metadata=file_metadata,
output_file_name=output_file_name,

View file

@ -85,6 +85,12 @@ def mock_entry_to_dict(
"thumbnail_ext": thumbnail_ext,
"info_json_ext": "info.json",
"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,
}