~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_setup.py

  • Committer: Matthieu Moy
  • Date: 2006-09-09 16:43:09 UTC
  • mto: (1993.2.3 test-setup-skip)
  • mto: This revision was merged to the branch mainline in revision 2013.
  • Revision ID: Matthieu.Moy@imag.fr-20060909164309-4fdfb7759964c51b
Test for the presence of the Makefile

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
        if not os.path.isfile('setup.py'):
48
48
            raise TestSkipped('There is no setup.py file in current directory')
49
49
        try:
50
 
            import distutils.core
 
50
            import distutils.sysconfig
 
51
            makefile_path = distutils.sysconfig.get_makefile_filename()
 
52
            if not os.path.exists(makefile_path):
 
53
                raise TestSkipped('You must have the python Makefile installed to run this test.'
 
54
                                  ' Usually this can be found by installing "python-dev"')
51
55
        except ImportError:
52
56
            raise TestSkipped('You must have distutils installed to run this test.'
53
57
                              ' Usually this can be found by installing "python-dev"')