diff --git a/test/runner/lib/sanity.py b/test/runner/lib/sanity.py index c3c32dd172..74faba7f26 100644 --- a/test/runner/lib/sanity.py +++ b/test/runner/lib/sanity.py @@ -451,7 +451,10 @@ def command_sanity_pylint(args, targets): skip_paths = skip_fd.read().splitlines() with open('test/sanity/pylint/disable.txt', 'r') as disable_fd: - disable = set(disable_fd.read().splitlines()) + disable = set(c for c in disable_fd.read().splitlines() if not c.strip().startswith('#')) + + with open('test/sanity/pylint/enable.txt', 'r') as enable_fd: + enable = set(c for c in enable_fd.read().splitlines() if not c.strip().startswith('#')) skip_paths_set = set(skip_paths) @@ -469,6 +472,7 @@ def command_sanity_pylint(args, targets): '--ignored-modules', '_MovedItems', '--output-format', 'json', '--disable', ','.join(sorted(disable)), + '--enable', ','.join(sorted(enable)), ] + paths env = ansible_environment(args) diff --git a/test/sanity/pylint/enable.txt b/test/sanity/pylint/enable.txt new file mode 100644 index 0000000000..224cd8b175 --- /dev/null +++ b/test/sanity/pylint/enable.txt @@ -0,0 +1 @@ +#wildcard-import