projects
/
youtube-dl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
0563f7a
)
[test_YoutubeDL] Add test for #11163
author
Sergey M․
<dstftw@gmail.com>
Sat, 15 Apr 2017 18:14:05 +0000
(
01:14
+0700)
committer
Sergey M․
<dstftw@gmail.com>
Sat, 15 Apr 2017 18:14:05 +0000
(
01:14
+0700)
test/test_YoutubeDL.py
patch
|
blob
|
history
diff --git
a/test/test_YoutubeDL.py
b/test/test_YoutubeDL.py
index 8491a88bd2f4730cd1af4e39d936966d6e1d3bb1..75945e38f837fc11496856180336fc2828121cca 100644
(file)
--- a/
test/test_YoutubeDL.py
+++ b/
test/test_YoutubeDL.py
@@
-755,6
+755,7
@@
class TestYoutubeDL(unittest.TestCase):
'_type': 'url_transparent',
'url': 'foo2:',
'ie_key': 'Foo2',
'_type': 'url_transparent',
'url': 'foo2:',
'ie_key': 'Foo2',
+ 'title': 'foo1 title'
}
class Foo2IE(InfoExtractor):
}
class Foo2IE(InfoExtractor):
@@
-771,7
+772,7
@@
class TestYoutubeDL(unittest.TestCase):
_VALID_URL = r'foo3:'
def _real_extract(self, url):
_VALID_URL = r'foo3:'
def _real_extract(self, url):
- return _make_result([{'url': TEST_URL}])
+ return _make_result([{'url': TEST_URL}]
, title='foo3 title'
)
ydl.add_info_extractor(Foo1IE(ydl))
ydl.add_info_extractor(Foo2IE(ydl))
ydl.add_info_extractor(Foo1IE(ydl))
ydl.add_info_extractor(Foo2IE(ydl))
@@
-779,6
+780,7
@@
class TestYoutubeDL(unittest.TestCase):
ydl.extract_info('foo1:')
downloaded = ydl.downloaded_info_dicts[0]
self.assertEqual(downloaded['url'], TEST_URL)
ydl.extract_info('foo1:')
downloaded = ydl.downloaded_info_dicts[0]
self.assertEqual(downloaded['url'], TEST_URL)
+ self.assertEqual(downloaded['title'], 'foo1 title')
if __name__ == '__main__':
if __name__ == '__main__':