1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-01-24 20:43:22 +08:00

[test/test_download] In test we download 10000 bytes at max

Also removed workaround in seznamzpravy extractor test.
This commit is contained in:
Petr Novak 2017-11-04 23:25:16 +01:00
parent b804f150ec
commit 87c82b2b3d
2 changed files with 2 additions and 4 deletions

View File

@ -216,7 +216,7 @@ def generator(test_case, tname):
expected_minsize = tc.get('file_minsize', 10000)
if expected_minsize is not None:
if params.get('test'):
expected_minsize = max(expected_minsize, 10000)
expected_minsize = min(expected_minsize, 10000)
got_fsize = os.path.getsize(tc_filename)
assertGreaterEqual(
self, got_fsize, expected_minsize,

View File

@ -16,9 +16,7 @@ class SeznamZpravyIE(InfoExtractor):
_TESTS = [{
# two videos on one page, with SDN URL
'url': 'https://www.seznam.cz/zpravy/clanek/jejich-svet-na-nas-utoci-je-lepsi-branit-se-na-jejich-pisecku-rika-reziser-a-major-v-zaloze-marhoul-35990',
'params': {'skip_download': True},
# ^ this is here instead of 'file_minsize': 1586, which does not work because
# test_download.py forces expected_minsize to at least 10k when test is running
'file_minsize': 1586,
'info_dict': {
'id': '35990',
'ext': 'mp4',