[diffoscope] 01/01: Correct logic of module_exists, ensuring we correctly skip the debian.deb822 tests when python3-debian is not installed. (Closes: #854745)
Chris Lamb
chris at chris-lamb.co.uk
Fri Feb 10 06:38:20 CET 2017
This is an automated email from the git hooks/post-receive script.
lamby pushed a commit to branch master
in repository diffoscope.
commit 520f8c6998c11b0cddefb75a52e877d7930270d3
Author: Chris Lamb <lamby at debian.org>
Date: Fri Feb 10 18:18:28 2017 +1300
Correct logic of module_exists, ensuring we correctly skip the debian.deb822 tests when python3-debian is not installed. (Closes: #854745)
Signed-off-by: Chris Lamb <lamby at debian.org>
---
tests/comparators/utils/tools.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/comparators/utils/tools.py b/tests/comparators/utils/tools.py
index 1e324cb..5841853 100644
--- a/tests/comparators/utils/tools.py
+++ b/tests/comparators/utils/tools.py
@@ -64,7 +64,7 @@ def get_supported_elf_formats():
def skip_unless_module_exists(name):
def module_exists(x):
try:
- return importlib.util.find_spec(x) is None
+ return importlib.util.find_spec(x) is not None
except ImportError:
# Probing for submodules (eg. ``debian.deb822``) will attempt to
# import ``debian`` so we must handle that failing.
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/diffoscope.git
More information about the diffoscope
mailing list