]> jfr.im git - yt-dlp.git/blobdiff - test/test_netrc.py
[test:download] Raise on network errors (#10283)
[yt-dlp.git] / test / test_netrc.py
index 94a703406b1000ae09ae78ebc3197f3c2b801b7c..1e0f4ee3b27b0f89b93f9d2e07403069f6ac9f98 100644 (file)
@@ -1,9 +1,10 @@
-# coding: utf-8
-from __future__ import unicode_literals
+#!/usr/bin/env python3
 
+# Allow direct execution
 import os
 import sys
 import unittest
+
 sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
 
@@ -20,7 +21,7 @@ def test_netrc_present(self):
                 continue
             self.assertTrue(
                 ie._NETRC_MACHINE,
-                'Extractor %s supports login, but is missing a _NETRC_MACHINE property' % ie.IE_NAME)
+                f'Extractor {ie.IE_NAME} supports login, but is missing a _NETRC_MACHINE property')
 
 
 if __name__ == '__main__':