]> granicus.if.org Git - python/commitdiff
fixed warning and error message
authorTarek Ziadé <ziade.tarek@gmail.com>
Sat, 24 Oct 2009 15:51:30 +0000 (15:51 +0000)
committerTarek Ziadé <ziade.tarek@gmail.com>
Sat, 24 Oct 2009 15:51:30 +0000 (15:51 +0000)
Lib/distutils/command/build_py.py
Lib/distutils/command/install_lib.py
Lib/distutils/tests/test_build_py.py
Lib/distutils/tests/test_install_lib.py
Lib/distutils/util.py

index 9b9f551830015486ecefcb3b2cafae92d43e96f2..5c7b473b045d7708001492cc2770a175333eb06f 100644 (file)
@@ -374,7 +374,7 @@ class build_py(Command):
 
     def byte_compile(self, files):
         if sys.dont_write_bytecode:
-            self.warn('byte-compile not supported on this platform, skipping.')
+            self.warn('byte-compiling is disabled, skipping.')
             return
 
         from distutils.util import byte_compile
index 7b4b45be79f025630d12d455d9f0c450bba378eb..043e8b6e27151e959d123938720a6d4978ca5701 100644 (file)
@@ -121,7 +121,7 @@ class install_lib(Command):
 
     def byte_compile(self, files):
         if sys.dont_write_bytecode:
-            self.warn('byte-compile not supported on this platform, skipping.')
+            self.warn('byte-compiling is disabled, skipping.')
             return
 
         from distutils.util import byte_compile
index e8c7ca921c0e49f4e8f6a48d1431ebf55a45c61b..bfe61542735f2a228cf8229cb6b3f943b80be2c9 100644 (file)
@@ -103,7 +103,7 @@ class BuildPyTestCase(support.TempdirManager,
         finally:
             sys.dont_write_bytecode = old_dont_write_bytecode
 
-        self.assertTrue('byte-compile not supported ' in self.logs[0][1])
+        self.assertTrue('byte-compiling is disabled' in self.logs[0][1])
 
 def test_suite():
     return unittest.makeSuite(BuildPyTestCase)
index fab66d15ae82f5488b8045f29e5992512506b2fb..99a6d9062727972757a07fe29e1c0cac10055b5f 100644 (file)
@@ -92,7 +92,7 @@ class InstallLibTestCase(support.TempdirManager,
         finally:
             sys.dont_write_bytecode = old_dont_write_bytecode
 
-        self.assertTrue('byte-compile not supported ' in self.logs[0][1])
+        self.assertTrue('byte-compiling is disabled' in self.logs[0][1])
 
 def test_suite():
     return unittest.makeSuite(InstallLibTestCase)
index a87ef44a272ae60cff4ffc72adb14e531ba5580b..6bff44f786d344a868dcadd4fc16f90f66421f72 100644 (file)
@@ -448,7 +448,7 @@ def byte_compile(py_files, optimize=0, force=0, prefix=None, base_dir=None,
     """
     # nothing is done if sys.dont_write_bytecode is True
     if sys.dont_write_bytecode:
-        raise DistutilsByteCompileError('byte-compiling not supported.')
+        raise DistutilsByteCompileError('byte-compiling is disabled.')
 
     # First, if the caller didn't force us into direct or indirect mode,
     # figure out which mode we should be in.  We take a conservative