integration-test: enable running from JHBuild

https://bugs.freedesktop.org/show_bug.cgi?id=99763
This commit is contained in:
Christian Kellner 2017-03-21 18:07:41 +00:00 committed by Bastien Nocera
parent b292ee2035
commit 90aec997ce

View file

@ -87,6 +87,11 @@ class Tests(dbusmock.DBusTestCase):
cls.daemon_path = os.path.join(builddir, 'src', 'upowerd')
print('Testing binaries from local build tree')
cls.local_daemon = True
elif os.environ.get('UNDER_JHBUILD', False):
jhbuild_prefix = os.environ['JHBUILD_PREFIX']
cls.daemon_path = os.path.join(jhbuild_prefix, 'libexec', 'upowerd')
print('Testing binaries from JHBuild')
cls.local_daemon = False
else:
print('Testing installed system binaries')
cls.daemon_path = None