From acf7b106c93dd7a2de3ce609b5fda512c352e528 Mon Sep 17 00:00:00 2001 From: Alexei Znamensky <103110+russoz@users.noreply.github.com> Date: Sun, 27 Jun 2021 19:39:08 +1200 Subject: [PATCH] _mount module utils - fixed sanity checks (#2883) * updated _mount.py, removed ignore lines * added changelog fragment --- changelogs/fragments/2883-_mount-fixed-sanity-checks.yml | 2 ++ plugins/module_utils/_mount.py | 4 ++++ tests/sanity/ignore-2.10.txt | 2 -- tests/sanity/ignore-2.11.txt | 2 -- tests/sanity/ignore-2.12.txt | 2 -- tests/sanity/ignore-2.9.txt | 2 -- 6 files changed, 6 insertions(+), 8 deletions(-) create mode 100644 changelogs/fragments/2883-_mount-fixed-sanity-checks.yml diff --git a/changelogs/fragments/2883-_mount-fixed-sanity-checks.yml b/changelogs/fragments/2883-_mount-fixed-sanity-checks.yml new file mode 100644 index 0000000000..35496e1233 --- /dev/null +++ b/changelogs/fragments/2883-_mount-fixed-sanity-checks.yml @@ -0,0 +1,2 @@ +bugfixes: + - _mount module utils - fixed the sanity checks (https://github.com/ansible-collections/community.general/pull/2883). diff --git a/plugins/module_utils/_mount.py b/plugins/module_utils/_mount.py index 62feb354cc..58be0e8b68 100644 --- a/plugins/module_utils/_mount.py +++ b/plugins/module_utils/_mount.py @@ -48,6 +48,10 @@ # agrees to be bound by the terms and conditions of this License # Agreement. +from __future__ import absolute_import, division, print_function + +__metaclass__ = type + import os diff --git a/tests/sanity/ignore-2.10.txt b/tests/sanity/ignore-2.10.txt index c9d750f417..bdb3ca4e9a 100644 --- a/tests/sanity/ignore-2.10.txt +++ b/tests/sanity/ignore-2.10.txt @@ -1,6 +1,4 @@ plugins/module_utils/cloud.py pylint:bad-option-value # a pylint test that is disabled was modified over time -plugins/module_utils/_mount.py future-import-boilerplate -plugins/module_utils/_mount.py metaclass-boilerplate plugins/modules/cloud/lxc/lxc_container.py use-argspec-type-path plugins/modules/cloud/lxc/lxc_container.py validate-modules:use-run-command-not-popen plugins/modules/cloud/misc/rhevm.py validate-modules:parameter-state-invalid-choice diff --git a/tests/sanity/ignore-2.11.txt b/tests/sanity/ignore-2.11.txt index 1311638dbc..34889a2651 100644 --- a/tests/sanity/ignore-2.11.txt +++ b/tests/sanity/ignore-2.11.txt @@ -1,5 +1,3 @@ -plugins/module_utils/_mount.py future-import-boilerplate -plugins/module_utils/_mount.py metaclass-boilerplate plugins/modules/cloud/lxc/lxc_container.py use-argspec-type-path plugins/modules/cloud/lxc/lxc_container.py validate-modules:use-run-command-not-popen plugins/modules/cloud/misc/rhevm.py validate-modules:parameter-state-invalid-choice diff --git a/tests/sanity/ignore-2.12.txt b/tests/sanity/ignore-2.12.txt index f5b7d772fc..6e14759c9d 100644 --- a/tests/sanity/ignore-2.12.txt +++ b/tests/sanity/ignore-2.12.txt @@ -1,5 +1,3 @@ -plugins/module_utils/_mount.py future-import-boilerplate -plugins/module_utils/_mount.py metaclass-boilerplate plugins/modules/cloud/lxc/lxc_container.py use-argspec-type-path plugins/modules/cloud/lxc/lxc_container.py validate-modules:use-run-command-not-popen plugins/modules/cloud/misc/rhevm.py validate-modules:parameter-state-invalid-choice diff --git a/tests/sanity/ignore-2.9.txt b/tests/sanity/ignore-2.9.txt index c8c5ff0d25..33f3d183d4 100644 --- a/tests/sanity/ignore-2.9.txt +++ b/tests/sanity/ignore-2.9.txt @@ -1,6 +1,4 @@ plugins/module_utils/cloud.py pylint:bad-option-value # a pylint test that is disabled was modified over time -plugins/module_utils/_mount.py future-import-boilerplate -plugins/module_utils/_mount.py metaclass-boilerplate plugins/modules/cloud/lxc/lxc_container.py use-argspec-type-path plugins/modules/cloud/lxc/lxc_container.py validate-modules:use-run-command-not-popen plugins/modules/cloud/rackspace/rax.py use-argspec-type-path