Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: make comparison work with ansible 2.9/jinja 2.7 #411

Merged
merged 1 commit into from
Dec 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions tests/test-verify-pool.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,13 @@

- name: Verify that VG shared value checks out
assert:
that: (storage_test_pool.shared | bool) == ('1' in vgs_dump.stdout)
that: storage_test_pool.shared == actual
msg: >-
Shared VG presence ({{ storage_test_pool.shared }})
does not match its expected state ({{ '1' in vgs_dump.stdout }})
Shared VG presence expected state ({{ storage_test_pool.shared }})
does not match its actual state ({{ actual }})
when: storage_test_pool.type == 'lvm' and storage_test_pool.state == 'present'
vars:
actual: "{{ '1' in vgs_dump.stdout }}"

- name: Verify pool subset
include_tasks: "test-verify-pool-{{ storage_test_pool_subset }}.yml"
Expand Down
15 changes: 15 additions & 0 deletions tests/tests_lvm_pool_shared_nvme_generated.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
# This file was generated by generate_tests.py
- name: Run test tests_lvm_pool_shared.yml for nvme
hosts: all
tags:
- tests::nvme
tasks:
- name: Set disk interface for test
set_fact:
storage_test_use_interface: "nvme"

- name: Import playbook
import_playbook: tests_lvm_pool_shared.yml
tags:
- tests::nvme
15 changes: 15 additions & 0 deletions tests/tests_lvm_pool_shared_scsi_generated.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
# This file was generated by generate_tests.py
- name: Run test tests_lvm_pool_shared.yml for scsi
hosts: all
tags:
- tests::scsi
tasks:
- name: Set disk interface for test
set_fact:
storage_test_use_interface: "scsi"

- name: Import playbook
import_playbook: tests_lvm_pool_shared.yml
tags:
- tests::scsi
Loading