[utils] Skip missing params in cli_bool_option (closes #13865)
[youtube-dl] / test / test_utils.py
index 7803e5bc74663371620bf12ac09656c0fbbdaf96..2aab16b97c300ee1858cffba0eff3f352009a404 100644 (file)
@@ -1182,6 +1182,10 @@ part 3</font></u>
             cli_bool_option(
                 {'nocheckcertificate': False}, '--check-certificate', 'nocheckcertificate', 'false', 'true', '='),
             ['--check-certificate=true'])
+        self.assertEqual(
+            cli_bool_option(
+                {}, '--check-certificate', 'nocheckcertificate', 'false', 'true', '='),
+            [])
 
     def test_ohdave_rsa_encrypt(self):
         N = 0xab86b6371b5318aaa1d3c9e612a9f1264f372323c8c0f19875b5fc3b3fd3afcc1e5bec527aa94bfa85bffc157e4245aebda05389a5357b75115ac94f074aefcd