diff --git a/needles/anaconda/partitioning/add.json b/needles/anaconda/partitioning/add.json new file mode 100644 index 00000000..aaaa67dc --- /dev/null +++ b/needles/anaconda/partitioning/add.json @@ -0,0 +1,15 @@ +{ + "properties": [], + "tags": [ + "anaconda_part_add" + ], + "area": [ + { + "xpos": 22, + "ypos": 630, + "width": 53, + "height": 14, + "type": "match" + } + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/add.png b/needles/anaconda/partitioning/add.png new file mode 100644 index 00000000..271003f6 Binary files /dev/null and b/needles/anaconda/partitioning/add.png differ diff --git a/needles/anaconda/partitioning/add_mountpoint.json b/needles/anaconda/partitioning/add_mountpoint.json new file mode 100644 index 00000000..8f97ef00 --- /dev/null +++ b/needles/anaconda/partitioning/add_mountpoint.json @@ -0,0 +1,15 @@ +{ + "properties": [], + "tags": [ + "anaconda_part_add_mountpoint" + ], + "area": [ + { + "xpos": 546, + "ypos": 479, + "width": 109, + "height": 17, + "type": "match" + } + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/add_mountpoint.png b/needles/anaconda/partitioning/add_mountpoint.png new file mode 100644 index 00000000..9db7aa7a Binary files /dev/null and b/needles/anaconda/partitioning/add_mountpoint.png differ diff --git a/needles/anaconda/partitioning/blivet/anaconda_blivet_part_fs_ext4.json b/needles/anaconda/partitioning/blivet/anaconda_blivet_part_fs_ext4.json new file mode 100644 index 00000000..a076431b --- /dev/null +++ b/needles/anaconda/partitioning/blivet/anaconda_blivet_part_fs_ext4.json @@ -0,0 +1,15 @@ +{ + "area": [ + { + "xpos": 398, + "ypos": 295, + "width": 32, + "height": 20, + "type": "match" + } + ], + "properties": [], + "tags": [ + "anaconda_blivet_part_fs_ext4" + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/blivet/anaconda_blivet_part_fs_ext4.png b/needles/anaconda/partitioning/blivet/anaconda_blivet_part_fs_ext4.png new file mode 100644 index 00000000..9430a00f Binary files /dev/null and b/needles/anaconda/partitioning/blivet/anaconda_blivet_part_fs_ext4.png differ diff --git a/needles/anaconda/partitioning/device_reformat.json b/needles/anaconda/partitioning/device_reformat.json new file mode 100644 index 00000000..fc3b675d --- /dev/null +++ b/needles/anaconda/partitioning/device_reformat.json @@ -0,0 +1,15 @@ +{ + "properties": [], + "tags": [ + "anaconda_part_device_reformat" + ], + "area": [ + { + "xpos": 614, + "ypos": 386, + "width": 80, + "height": 19, + "type": "match" + } + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/device_reformat.png b/needles/anaconda/partitioning/device_reformat.png new file mode 100644 index 00000000..e771fc2b Binary files /dev/null and b/needles/anaconda/partitioning/device_reformat.png differ diff --git a/needles/anaconda/partitioning/mounpoint_selected.json b/needles/anaconda/partitioning/mounpoint_selected.json new file mode 100644 index 00000000..055c1891 --- /dev/null +++ b/needles/anaconda/partitioning/mounpoint_selected.json @@ -0,0 +1,15 @@ +{ + "properties": [], + "tags": [ + "anaconda_part_mountpoint_selected" + ], + "area": [ + { + "xpos": 501, + "ypos": 152, + "width": 87, + "height": 25, + "type": "match" + } + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/mounpoint_selected.png b/needles/anaconda/partitioning/mounpoint_selected.png new file mode 100644 index 00000000..e34e1d7a Binary files /dev/null and b/needles/anaconda/partitioning/mounpoint_selected.png differ diff --git a/needles/anaconda/partitioning/select_boot.json b/needles/anaconda/partitioning/select_boot.json new file mode 100644 index 00000000..57259fe6 --- /dev/null +++ b/needles/anaconda/partitioning/select_boot.json @@ -0,0 +1,15 @@ +{ + "properties": [], + "tags": [ + "anaconda_part_select_boot" + ], + "area": [ + { + "xpos": 53, + "ypos": 434, + "width": 44, + "height": 18, + "type": "match" + } + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/select_boot.png b/needles/anaconda/partitioning/select_boot.png new file mode 100644 index 00000000..8e257035 Binary files /dev/null and b/needles/anaconda/partitioning/select_boot.png differ diff --git a/needles/anaconda/partitioning/use_current.json b/needles/anaconda/partitioning/use_current.json new file mode 100644 index 00000000..52cd37f2 --- /dev/null +++ b/needles/anaconda/partitioning/use_current.json @@ -0,0 +1,15 @@ +{ + "properties": [], + "tags": [ + "anaconda_part_use_current" + ], + "area": [ + { + "xpos": 29, + "ypos": 347, + "width": 108, + "height": 18, + "type": "match" + } + ] +} \ No newline at end of file diff --git a/needles/anaconda/partitioning/use_current.png b/needles/anaconda/partitioning/use_current.png new file mode 100644 index 00000000..82ffc928 Binary files /dev/null and b/needles/anaconda/partitioning/use_current.png differ diff --git a/tests/disk_custom_resize.pm b/tests/disk_custom_resize.pm new file mode 100644 index 00000000..2f995650 --- /dev/null +++ b/tests/disk_custom_resize.pm @@ -0,0 +1,77 @@ +use base "anacondatest"; +use strict; +use testapi; +use anaconda; +use utils; + +sub run { + my $self = shift; + # Navigate to "Installation destionation" and select blivet-gui + # to manipulate the partitions. This will be automatically + # done using the following method, because PARTITIONING starts + # with "custom_blivet". + select_disks(); + assert_and_click "anaconda_spoke_done"; + + # The following procedure will use Custom Partitioning to resize the root partition from + # a previous Linux installation and prepare the disk for new installation + # which will be then followed through. + + # Custom partitioning shows that an existing installations is there on the disk, + # we need to select it to proceed. + assert_and_click "anaconda_part_use_current"; + + # At first, we will recreate the /boot mountpoint in the existing installation + # and reformat it. + # + assert_and_click "anaconda_part_select_boot"; + # navigate to "Mountpoint" + while (!check_screen "anaconda_part_mountpoint_selected") { + send_key "tab"; + } + type_very_safely "/boot"; + assert_and_click "anaconda_part_device_reformat"; + assert_and_click "anaconda_part_update_settings"; + + # Then mount the Swap partition. + assert_and_click "anaconda_part_select_swap"; + assert_and_click "anaconda_part_device_reformat"; + assert_and_click "anaconda_part_update_settings"; + + # Now resize and format the current root partition + assert_and_click "anaconda_part_select_root"; + # Navigate to Mountpoint + while (!check_screen "anaconda_part_mountpoint_selected") { + send_key "tab"; + } + type_very_safely "/"; + # Skip to the Size window + send_key "tab"; + type_very_safely "13 GiB"; + # Reformat and update the partition + assert_and_click "anaconda_part_device_reformat"; + assert_and_click "anaconda_part_update_settings"; + + # Add new /home partition into the emptied space. + assert_and_click "anaconda_part_add"; + + # The previous step brings us into a mountpoint field + # of the pop-up window, so we only need to fill the value in. + # Also, it seems that leaving the size field empty automatically + # suggests to use the remaining free space. + type_very_safely "/home"; + send_key "tab"; + assert_and_click "anaconda_part_add_mountpoint"; + + # Close the spoke. + assert_and_click "anaconda_spoke_done"; + + # Confirm changes + assert_and_click "anaconda_part_accept_changes"; +} + +sub test_flags { + return { fatal => 1 }; +} + +1;