diff options
author | pukkandan <pukkandan.ytdlp@gmail.com> | 2022-04-24 21:58:18 +0530 |
---|---|---|
committer | pukkandan <pukkandan.ytdlp@gmail.com> | 2022-04-26 05:43:20 +0530 |
commit | 9196cbfe8bb7a6eb46037735b76f21963dfdc61a (patch) | |
tree | 050c5df59f73c0dc15e99ae6388595ea6e00986f /test | |
parent | 9cd080508db2daf625994f9aef29790f4bca7996 (diff) | |
download | hypervideo-pre-9196cbfe8bb7a6eb46037735b76f21963dfdc61a.tar.lz hypervideo-pre-9196cbfe8bb7a6eb46037735b76f21963dfdc61a.tar.xz hypervideo-pre-9196cbfe8bb7a6eb46037735b76f21963dfdc61a.zip |
[compat] Ensure submodules are correctly wrapped
Diffstat (limited to 'test')
-rw-r--r-- | test/test_compat.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/test_compat.py b/test/test_compat.py index 8e40a4180..9b185853d 100644 --- a/test/test_compat.py +++ b/test/test_compat.py @@ -7,6 +7,7 @@ import unittest sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) +from yt_dlp import compat from yt_dlp.compat import ( compat_etree_fromstring, compat_expanduser, @@ -21,6 +22,12 @@ from yt_dlp.compat import ( class TestCompat(unittest.TestCase): + def test_compat_passthrough(self): + with self.assertWarns(DeprecationWarning): + compat.compat_basestring + + compat.asyncio.events # Must not raise error + def test_compat_getenv(self): test_str = 'ัะตัั' compat_setenv('yt_dlp_COMPAT_GETENV', test_str) |