From ab43b88d952d6949dd5611caf735eceb1a8621ba Mon Sep 17 00:00:00 2001 From: "patchback[bot]" <45432694+patchback[bot]@users.noreply.github.com> Date: Fri, 5 Feb 2021 08:29:21 +0100 Subject: [PATCH] Make sure mercurial is also installed on OpenSuSE. (#1734) (#1737) (cherry picked from commit 701a89eb1ce88e45b30b79cffc909e5ad0c8af37) Co-authored-by: Felix Fontein --- tests/integration/targets/hg/tasks/install.yml | 5 +++++ tests/integration/targets/hg/tasks/uninstall.yml | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/tests/integration/targets/hg/tasks/install.yml b/tests/integration/targets/hg/tasks/install.yml index c4a1aba90e..40aba5e2fc 100644 --- a/tests/integration/targets/hg/tasks/install.yml +++ b/tests/integration/targets/hg/tasks/install.yml @@ -36,6 +36,11 @@ name: mercurial when: ansible_facts.pkg_mgr in ['pkgng', 'community.general.pkgng'] +- name: install mercurial (zypper) + package: + name: mercurial + when: ansible_facts.pkg_mgr in ['zypper', 'community.general.zypper'] + - name: preserve the updated python command: cp -av "{{ which_python.stdout }}" "{{ which_python.stdout }}.updated" diff --git a/tests/integration/targets/hg/tasks/uninstall.yml b/tests/integration/targets/hg/tasks/uninstall.yml index 55c5efcb8c..305a2ffd33 100644 --- a/tests/integration/targets/hg/tasks/uninstall.yml +++ b/tests/integration/targets/hg/tasks/uninstall.yml @@ -35,6 +35,12 @@ autoremove: yes when: ansible_facts.pkg_mgr in ['pkgng', 'community.general.pkgng'] +- name: uninstall packages which were not originally installed (zypper) + package: + name: mercurial + state: absent + when: ansible_facts.pkg_mgr in ['zypper', 'community.general.zypper'] + - name: restore the default python raw: mv "{{ which_python.stdout }}.default" "{{ which_python.stdout }}"