[test_utils] Do not use dash in env variables' names
authorSergey M․ <dstftw@gmail.com>
Sat, 25 Mar 2017 20:22:48 +0000 (03:22 +0700)
committerSergey M․ <dstftw@gmail.com>
Sat, 25 Mar 2017 20:22:48 +0000 (03:22 +0700)
test/test_utils.py

index b9a02666d45c93174767b3d42ca7933ee2021cb1..aa4569b819e368381a9ee100a6060e38ae0ce065 100644 (file)
@@ -221,12 +221,12 @@ class TestUtil(unittest.TestCase):
         def env(var):
             return '%{0}%'.format(var) if sys.platform == 'win32' else '${0}'.format(var)
 
-        compat_setenv('YOUTUBE-DL-EXPATH-PATH', 'expanded')
-        self.assertEqual(expand_path(env('YOUTUBE-DL-EXPATH-PATH')), 'expanded')
-        self.assertEqual(expand_path(env('HOMEPATH')), compat_getenv('HOMEPATH'))
+        compat_setenv('YOUTUBE_DL_EXPATH_PATH', 'expanded')
+        self.assertEqual(expand_path(env('YOUTUBE_DL_EXPATH_PATH')), 'expanded')
+        self.assertEqual(expand_path(env('HOME')), compat_getenv('HOME'))
         self.assertEqual(expand_path('~'), compat_getenv('HOME'))
         self.assertEqual(
-            expand_path('~/%s' % env('YOUTUBE-DL-EXPATH-PATH')),
+            expand_path('~/%s' % env('YOUTUBE_DL_EXPATH_PATH')),
             '%s/expanded' % compat_getenv('HOME'))
 
     def test_prepend_extension(self):