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 for btrfs custom storage scenario #382

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
52 changes: 52 additions & 0 deletions test/check-storage-cockpit
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,58 @@ class TestStorageCockpitIntegration(VirtInstallMachineCase, StorageCase):
self.assertTrue("/mnt/sysroot btrfs noauto,subvol=root 0 0" in fstab)
self.assertTrue("/mnt/sysroot/home btrfs noauto,subvol=home 0 0" in fstab)

@nondestructive
def testBtrfsAndConfigureedStorage(self):
b = self.browser
m = self.machine
i = Installer(b, m, scenario="use-configured-storage")
s = Storage(b, m)
r = Review(b, m)

i.open()
i.reach(i.steps.INSTALLATION_METHOD)
s.wait_scenario_visible("use-configured-storage", False)
s.check_single_disk_destination("vda")
s.modify_storage()
s.confirm_entering_cockpit_storage()
b.wait_visible(".cockpit-storage-integration-sidebar")

frame = "iframe[name='cockpit-storage']"
b._wait_present(frame)
b.switch_to_frame("cockpit-storage")
b._wait_present("#storage.ct-page-fill")

# Create GPT partition table
self.click_dropdown(self.card_row("Storage", 1), "Create partition table")
self.confirm()

# Create BIOS boot partition
self.click_dropdown(self.card_row("Storage", 2), "Create partition")
self.dialog({"size": 1, "type": "biosboot"})

# Create ext4 partition for /boot
self.click_dropdown(self.card_row("Storage", 3), "Create partition")
self.dialog({"size": 1070, "type": "ext4", "mount_point": "/boot"})

# Create Btrfs partition for /
self.click_dropdown(self.card_row("Storage", 4), "Create partition")
self.dialog({"type": "btrfs", "mount_point": "/"})

# Exit the cockpit-storage iframe
b.switch_to_top()

s.return_to_installation()
s.return_to_installation_confirm()

s.set_partitioning("use-configured-storage")

i.reach(i.steps.REVIEW)

# verify review screen
dev = "vda"
r.check_disk(dev, "16.1 GB vda (0x1af4)")

i.begin_installation(button_text="Install")


if __name__ == '__main__':
Expand Down
Loading