# HG changeset patch # User Denis Laxalde # Date 1453194196 -3600 # Node ID d7e8912549cd84974b669bd46a91857acb752e58 # Parent 8c3155a0ae5b512af4255ce6d60a71f02ede4c33 [test] Skip LDAP tests if any of the underlying programs is not found Some programs are in ldap-utils or ldapscripts, which may not be installed despite slapd may. Follow-up on 282880f81311. diff -r 8c3155a0ae5b -r d7e8912549cd cubicweb/server/test/unittest_ldapsource.py --- a/cubicweb/server/test/unittest_ldapsource.py Mon Jan 18 09:23:07 2016 +0100 +++ b/cubicweb/server/test/unittest_ldapsource.py Tue Jan 19 10:03:16 2016 +0100 @@ -116,8 +116,11 @@ @classmethod def setUpClass(cls): - if not os.path.exists('/usr/sbin/slapd'): - raise unittest.SkipTest('slapd not found') + for path in ('/usr/sbin/slapd', + '/usr/sbin/slapadd', + '/usr/bin/ldapmodify'): + if not os.path.exists(path): + raise unittest.SkipTest('%s not found' % path) from cubicweb.cwctl import init_cmdline_log_threshold init_cmdline_log_threshold(cls.config, cls.loglevel) cls._tmpdir = create_slapd_configuration(cls)