mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-29 16:11:22 -07:00
ModuleHelper - deprecate attribute VarDict (#3801)
* ModuleHelper - deprecate attribute VarDict * added changelog fragment
This commit is contained in:
parent
bc619bcefc
commit
2896131ca7
5 changed files with 40 additions and 2 deletions
|
@ -69,9 +69,25 @@
|
|||
a: 5
|
||||
b: foo
|
||||
c: bar
|
||||
trigger_depr_attr: true
|
||||
state: both_x_a
|
||||
register: state5
|
||||
|
||||
- ansible.builtin.set_fact:
|
||||
vardict_gt29:
|
||||
msg: >-
|
||||
ModuleHelper.VarDict attribute is deprecated, use VarDict from the
|
||||
ansible_collections.community.general.plugins.module_utils.mh.mixins.vars
|
||||
module instead
|
||||
version: 6.0.0
|
||||
collection_name: community.general
|
||||
vardict_29:
|
||||
msg: >-
|
||||
ModuleHelper.VarDict attribute is deprecated, use VarDict from the
|
||||
ansible_collections.community.general.plugins.module_utils.mh.mixins.vars
|
||||
module instead
|
||||
version: 6.0.0
|
||||
|
||||
- name: assert state5
|
||||
assert:
|
||||
that:
|
||||
|
@ -80,3 +96,6 @@
|
|||
- state5.c == "bar"
|
||||
- state5.result == "foobarfoobarfoobarfoobarfoobar"
|
||||
- state5 is changed
|
||||
- vardict_depr in state5.deprecations
|
||||
vars:
|
||||
vardict_depr: '{{ (ansible_version.major == 2 and ansible_version.minor == 9) | ternary(vardict_29, vardict_gt29) }}'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue