Skip to content

Commit

Permalink
tests: Require same sector size disks for LVM tests
Browse files Browse the repository at this point in the history
LVM VGs cannot be created on top of disks with different sector
sizes so for tests that need multiple disks we need to make sure
we get unused disks with the same sector size.

Resolves: RHEL-25994
  • Loading branch information
vojtechtrefny authored and richm committed May 30, 2024
1 parent 368ecd0 commit d8c5938
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tests/tests_change_fs_use_partitions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
include_tasks: get_unused_disk.yml
vars:
min_size: "{{ volume_size }}"
max_return: 2
max_return: 1

- name: Create an LVM partition with the default file system type
include_role:
Expand Down
1 change: 1 addition & 0 deletions tests/tests_create_lvm_cache_then_remove.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
min_size: "{{ volume_group_size }}"
max_return: 2
disks_needed: 2
match_sector_size: true

- name: Create a cached LVM logical volume under volume group 'foo'
include_role:
Expand Down
1 change: 1 addition & 0 deletions tests/tests_create_thinp_then_remove.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
include_tasks: get_unused_disk.yml
vars:
max_return: 3
match_sector_size: true

- name: Create a thinpool device
include_role:
Expand Down
1 change: 1 addition & 0 deletions tests/tests_fatals_cache_volume.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
vars:
max_return: 2
disks_needed: 2
match_sector_size: true

- name: Verify that creating a cached partition volume fails
include_tasks: verify-role-failed.yml
Expand Down
1 change: 1 addition & 0 deletions tests/tests_lvm_multiple_disks_multiple_volumes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
min_size: "{{ volume_group_size }}"
max_return: 2
disks_needed: 2
match_sector_size: true

- name: >-
Create a logical volume spanning two physical volumes that changes its
Expand Down
1 change: 1 addition & 0 deletions tests/tests_lvm_pool_members.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
vars:
min_size: "{{ volume_group_size }}"
disks_needed: 3
match_sector_size: true

- name: Create volume group 'foo' with 3 PVs
include_role:
Expand Down

0 comments on commit d8c5938

Please sign in to comment.