From 46838054d25bb3e8fcc8210a6433ae788bfa3d12 Mon Sep 17 00:00:00 2001 From: omnom62 <75066712+omnom62@users.noreply.github.com> Date: Thu, 17 Apr 2025 06:50:24 +1000 Subject: TestModule profile patch (#414) * TestModule profile patch * changelog * linter fix --- changelogs/fragments/test_module_patch.yml | 3 +++ tests/unit/modules/utils.py | 3 +++ 2 files changed, 6 insertions(+) create mode 100644 changelogs/fragments/test_module_patch.yml diff --git a/changelogs/fragments/test_module_patch.yml b/changelogs/fragments/test_module_patch.yml new file mode 100644 index 00000000..557a941a --- /dev/null +++ b/changelogs/fragments/test_module_patch.yml @@ -0,0 +1,3 @@ +--- +trivial: + - util.py - Add mock _ANSIBLE_PROFILE to reflect changes to Ansible libs diff --git a/tests/unit/modules/utils.py b/tests/unit/modules/utils.py index 6489f13f..e2d17abd 100644 --- a/tests/unit/modules/utils.py +++ b/tests/unit/modules/utils.py @@ -20,6 +20,9 @@ def set_module_args(args): args = json.dumps({"ANSIBLE_MODULE_ARGS": args}) basic._ANSIBLE_ARGS = to_bytes(args) + profile = "legacy" + basic._ANSIBLE_PROFILE = profile + class AnsibleExitJson(Exception): pass -- cgit v1.2.3