fix extractor result tests
This commit is contained in:
@@ -165,7 +165,7 @@ class ResultJob(job.DownloadJob):
|
|||||||
self.hash_content = hashlib.sha1()
|
self.hash_content = hashlib.sha1()
|
||||||
if content:
|
if content:
|
||||||
self.fileobj = FakePathfmt(self.hash_content)
|
self.fileobj = FakePathfmt(self.hash_content)
|
||||||
self.get_downloader("http")._check_extension = lambda a, b: None
|
self.get_downloader("http").check_extension = lambda a, b: None
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
for msg in self.extractor:
|
for msg in self.extractor:
|
||||||
@@ -214,6 +214,7 @@ class FakePathfmt():
|
|||||||
self.hashobj = hashobj
|
self.hashobj = hashobj
|
||||||
self.path = ""
|
self.path = ""
|
||||||
self.size = 0
|
self.size = 0
|
||||||
|
self.keywords = {}
|
||||||
self.has_extension = True
|
self.has_extension = True
|
||||||
|
|
||||||
def __enter__(self):
|
def __enter__(self):
|
||||||
|
|||||||
Reference in New Issue
Block a user