diff options
| -rw-r--r-- | command/config.py | 1 | ||||
| -rw-r--r-- | tests/test_config_cmd.py | 15 |
2 files changed, 16 insertions, 0 deletions
diff --git a/command/config.py b/command/config.py index c3122055..ac80a54e 100644 --- a/command/config.py +++ b/command/config.py @@ -12,6 +12,7 @@ this header file lives". __revision__ = "$Id$" import sys, os, re + from distutils.core import Command from distutils.errors import DistutilsExecError from distutils.sysconfig import customize_compiler diff --git a/tests/test_config_cmd.py b/tests/test_config_cmd.py index af16d4c8..45d480ba 100644 --- a/tests/test_config_cmd.py +++ b/tests/test_config_cmd.py @@ -46,6 +46,21 @@ class ConfigTestCase(support.LoggingSilencer, match = cmd.search_cpp(pattern='command', body='// xxx') self.assertEquals(match, 1) + def test_finalize_options(self): + # finalize_options does a bit of transformation + # on options + pkg_dir, dist = self.create_dist() + cmd = config(dist) + cmd.include_dirs = 'one%stwo' % os.pathsep + cmd.libraries = 'one' + cmd.library_dirs = 'three%sfour' % os.pathsep + cmd.ensure_finalized() + + self.assertEquals(cmd.include_dirs, ['one', 'two']) + self.assertEquals(cmd.libraries, ['one']) + self.assertEquals(cmd.library_dirs, ['three', 'four']) + + def test_suite(): return unittest.makeSuite(ConfigTestCase) |
