fixed bdist_msi imports and added a test module for distutils.command.bdist_msi
This commit is contained in:
parent
ffd849618a
commit
b28e5d7e41
|
@ -6,15 +6,15 @@
|
|||
"""
|
||||
Implements the bdist_msi command.
|
||||
"""
|
||||
|
||||
import sys, os
|
||||
from sysconfig import get_python_version, get_platform
|
||||
|
||||
from distutils.core import Command
|
||||
from distutils.dir_util import remove_tree
|
||||
from distutils.sysconfig import get_python_version
|
||||
from distutils.version import StrictVersion
|
||||
from distutils.errors import DistutilsOptionError
|
||||
from distutils.util import get_platform
|
||||
from distutils import log
|
||||
|
||||
import msilib
|
||||
from msilib import schema, sequence, text
|
||||
from msilib import Directory, Feature, Dialog, add_data
|
||||
|
|
|
@ -0,0 +1,23 @@
|
|||
"""Tests for distutils.command.bdist_msi."""
|
||||
import unittest
|
||||
import sys
|
||||
|
||||
from distutils.tests import support
|
||||
|
||||
@unittest.skipUnless(sys.platform=="win32", "These tests are only for win32")
|
||||
class BDistMSITestCase(support.TempdirManager,
|
||||
support.LoggingSilencer,
|
||||
unittest.TestCase):
|
||||
|
||||
def test_minial(self):
|
||||
# minimal test XXX need more tests
|
||||
from distutils.command.bdist_msi import bdist_msi
|
||||
pkg_pth, dist = self.create_dist()
|
||||
cmd = bdist_msi(dist)
|
||||
cmd.ensure_finalized()
|
||||
|
||||
def test_suite():
|
||||
return unittest.makeSuite(BDistMSITestCase)
|
||||
|
||||
if __name__ == '__main__':
|
||||
test_support.run_unittest(test_suite())
|
Loading…
Reference in New Issue