1
0
mirror of https://github.com/mxpv/podsync.git synced 2024-05-11 05:55:04 +00:00
mxpv-podsync/cmd/updater/function_test.py

19 lines
560 B
Python
Raw Normal View History

2019-04-07 13:10:51 -07:00
import function
import unittest
TEST_URL = 'https://www.youtube.com/user/CNN/videos'
class TestUpdater(unittest.TestCase):
2019-04-07 14:59:39 -07:00
@unittest.skip('heavy test, run manually')
2019-04-07 13:10:51 -07:00
def test_get_50(self):
resp = function.handler({
'url': 'https://www.youtube.com/channel/UCd6MoB9NC6uYN2grvUNT-Zg',
'start': 1,
'count': 50,
'format': 'audio',
'quality': 'low',
}, None)
self.assertEqual(len(resp['Episodes']), 50)
self.assertEqual(resp['Episodes'][0]['ID'], resp['LastID'])