Debian Codegraph @

ansible_collections/community/general/tests/integration/targets/dnf_versionlock/tasks/lock_bash.yml

raw
1 ---
2 # Copyright (c) Ansible Project
3 # GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
4 # SPDX-License-Identifier: GPL-3.0-or-later
5
6 - name: Clear locklist
7 community.general.dnf_versionlock:
8 state: clean
9 register: clear_locklist
10
11 - assert:
12 that:
13 - clear_locklist.locklist_post | length == 0
14
15 - name: Lock installed package bash
16 community.general.dnf_versionlock:
17 name: bash
18 state: present
19 register: lock_bash
20
21 - assert:
22 that:
23 - lock_bash is changed
24 - lock_bash.locklist_post | length == 1
25
26 - name: Unlock installed package bash
27 community.general.dnf_versionlock:
28 name: bash
29 state: absent
30 register: unlock_bash
31
32 - assert:
33 that:
34 - unlock_bash is changed
35 - unlock_bash.locklist_post | length == 0
36 ...