From ca6f04954ce997847b6dcecf039e3dead15fabae Mon Sep 17 00:00:00 2001 From: Eric Bischoff Date: Mon, 2 Oct 2023 13:49:45 +0200 Subject: [PATCH] We are constrained to sync SLES on Uyuni --- .../core/srv_create_activationkey.feature | 10 ++++- .../allcli_update_activationkeys.feature | 41 +++++++++++++++++- .../reposync/srv_sync_fake_channels.feature | 43 +++++++++++++++++++ .../reposync/srv_sync_products.feature | 26 +++++++++++ .../buildhost_osimage_build_image.feature | 2 +- .../secondary/proxy_cobbler_pxeboot.feature | 7 ++- ...oxy_retail_pxeboot_and_mass_import.feature | 2 +- 7 files changed, 122 insertions(+), 9 deletions(-) diff --git a/testsuite/features/core/srv_create_activationkey.feature b/testsuite/features/core/srv_create_activationkey.feature index 40ff05cf08e0..bb1d2a0e7fc1 100644 --- a/testsuite/features/core/srv_create_activationkey.feature +++ b/testsuite/features/core/srv_create_activationkey.feature @@ -111,8 +111,16 @@ Feature: Create activation keys And I wait for child channels to appear And I enter "Build host Key x86_64" as "description" And I enter "BUILD-HOST-KEY-x86_64" as "key" - And I enter "20" as "usageLimit" And I check "Container Build Host" And I check "OS Image Build Host" And I click on "Create Activation Key" Then I should see a "Activation key Build host Key x86_64 has been created" text + + Scenario: Create an activation key for the terminal + When I follow the left menu "Systems > Activation Keys" + And I follow "Create Key" + And I wait for child channels to appear + And I enter "Terminal Key x86_64" as "description" + And I enter "TERMINAL-KEY-x86_64" as "key" + And I click on "Create Activation Key" + Then I should see a "Activation key Terminal Key x86_64 has been created" text diff --git a/testsuite/features/init_clients/allcli_update_activationkeys.feature b/testsuite/features/init_clients/allcli_update_activationkeys.feature index e138e2899ae1..362335ad9bea 100644 --- a/testsuite/features/init_clients/allcli_update_activationkeys.feature +++ b/testsuite/features/init_clients/allcli_update_activationkeys.feature @@ -148,7 +148,6 @@ Feature: Update activation keys Then I should see a "Activation key Proxy Key x86_64 has been modified" text @scc_credentials -@susemanager Scenario: Update build host key with synced base product When I follow the left menu "Systems > Activation Keys" And I follow "Build host Key x86_64" in the content area @@ -166,6 +165,44 @@ Feature: Update activation keys And I wait until "SLE-Module-Desktop-Applications15-SP4-Updates for x86_64" has been checked And I check "SLE-Module-Containers15-SP4-Pool for x86_64" And I wait until "SLE-Module-Containers15-SP4-Updates for x86_64" has been checked - And I check "Fake-RPM-SUSE-Channel" And I click on "Update Activation Key" Then I should see a "Activation key Build host Key x86_64 has been modified" text + +@scc_credentials + Scenario: Update terminal key with synced base product + When I follow the left menu "Systems > Activation Keys" + And I follow "Terminal Key x86_64" in the content area + And I wait for child channels to appear + And I select "SLE-Product-SLES15-SP4-Pool for x86_64" from "selectedBaseChannel" + And I wait for child channels to appear + And I include the recommended child channels + And I wait until "SLE-Module-Basesystem15-SP4-Pool for x86_64" has been checked + And I wait until "SLE-Module-Basesystem15-SP4-Updates for x86_64" has been checked + And I wait until "SLE-Module-Server-Applications15-SP4-Pool for x86_64" has been checked + And I wait until "SLE-Module-Server-Applications15-SP4-Updates for x86_64" has been checked + And I check "SLE-Module-DevTools15-SP4-Pool for x86_64" + And I wait until "SLE-Module-DevTools15-SP4-Updates for x86_64" has been checked + And I wait until "SLE-Module-Desktop-Applications15-SP4-Pool for x86_64" has been checked + And I wait until "SLE-Module-Desktop-Applications15-SP4-Updates for x86_64" has been checked + And I check "SLE-Module-Containers15-SP4-Pool for x86_64" + And I wait until "SLE-Module-Containers15-SP4-Updates for x86_64" has been checked + And I click on "Update Activation Key" + Then I should see a "Activation key Terminal Key x86_64 has been modified" text + +@susemanager + Scenario: Update terminal key with normal SUSE fake channel + When I follow the left menu "Systems > Activation Keys" + And I follow "Terminal Key x86_64" in the content area + And I wait for child channels to appear + And I check "Fake-RPM-SUSE-Channel" + And I click on "Update Activation Key" + Then I should see a "Activation key Terminal Key x86_64 has been modified" text + +@uyuni + Scenario: Update terminal key with specific fake channel + When I follow the left menu "Systems > Activation Keys" + And I follow "Terminal Key x86_64" in the content area + And I wait for child channels to appear + And I check "Fake-RPM-Terminal-Channel" + And I click on "Update Activation Key" + Then I should see a "Activation key Terminal Key x86_64 has been modified" text diff --git a/testsuite/features/reposync/srv_sync_fake_channels.feature b/testsuite/features/reposync/srv_sync_fake_channels.feature index bab31023d829..56a4c924fd16 100644 --- a/testsuite/features/reposync/srv_sync_fake_channels.feature +++ b/testsuite/features/reposync/srv_sync_fake_channels.feature @@ -47,3 +47,46 @@ Feature: Prepare fake SUSE channels Scenario: Verify state of Fake-RPM-SUSE-Channel custom channel Then "orion-dummy-1.1-1.1.x86_64.rpm" package should have been stored And solver file for "fake-rpm-suse-channel" should reference "orion-dummy-1.1-1.1.x86_64.rpm" + +@uyuni + Scenario: Add the terminal child channel to the base product channel + When I follow the left menu "Software > Manage > Channels" + And I follow "Create Channel" + And I enter "Fake-RPM-Terminal-Channel" as "Channel Name" + And I enter "fake-rpm-terminal-channel" as "Channel Label" + And I select "SLE-Product-SLES15-SP4-Pool for x86_64" from "Parent Channel" + And I select "x86_64" from "Architecture:" + And I enter "Fake-RPM-Terminal-Channel for testing" as "Channel Summary" + And I enter "Description for Fake-RPM-Terminal-Channel Child Channel." as "Channel Description" + And I click on "Create Channel" + Then I should see a "Channel Fake-RPM-Terminal-Channel created." text + +@uyuni + Scenario: Add the repository to the terminal child channel + When I follow the left menu "Software > Manage > Channels" + And I follow "Fake-RPM-Terminal-Channel" + And I enter "file:///etc/pki/rpm-gpg/uyuni-tools-gpg-pubkey-0d20833e.key" as "GPG key URL" + And I click on "Update Channel" + Then I should see a "Channel Fake-RPM-Terminal-Channel updated" text + When I follow "Repositories" in the content area + And I select the "fake-rpm-repo" repo + And I click on "Save Repositories" + Then I should see a "Fake-RPM-Terminal-Channel repository information was successfully updated" text + +@uyuni + Scenario: Synchronize the repository in the terminal channel + When I enable source package syncing + And I follow the left menu "Software > Manage > Channels" + And I follow "Fake-RPM-Terminal-Channel" + And I follow "Repositories" in the content area + And I follow "Sync" + And I wait at most 60 seconds until I do not see "Repository sync is running." text, refreshing the page + And I click on "Sync Now" + Then I should see a "Repository sync scheduled for Fake-RPM-Terminal-Channel." text + And I wait until the channel "fake-rpm-terminal-channel" has been synced + And I disable source package syncing + +@uyuni + Scenario: Verify state of Fake-RPM-Terminal-Channel custom channel + Then "orion-dummy-1.1-1.1.x86_64.rpm" package should have been stored + And solver file for "fake-rpm-terminal-channel" should reference "orion-dummy-1.1-1.1.x86_64.rpm" diff --git a/testsuite/features/reposync/srv_sync_products.feature b/testsuite/features/reposync/srv_sync_products.feature index 739fdbffdaf1..b59db89cb7de 100644 --- a/testsuite/features/reposync/srv_sync_products.feature +++ b/testsuite/features/reposync/srv_sync_products.feature @@ -62,6 +62,32 @@ Feature: Synchronize products in the products page of the Setup Wizard And I wait until I see "SUSE Linux Enterprise Server 15 SP4 x86_64" product has been added Then the SLE15 SP4 product should be added +@scc_credentials +@uyuni + Scenario: Add SLES 15 SP4 product with recommended sub-products for the build host and the terminal + When I follow the left menu "Admin > Setup Wizard > Products" + And I wait until I do not see "Loading" text + And I enter "SUSE Linux Enterprise Server 15 SP4" as the filtered product description + And I wait until I see "SUSE Linux Enterprise Server 15 SP4 x86_64" text + And I open the sub-list of the product "SUSE Linux Enterprise Server 15 SP4 x86_64" + And I open the sub-list of the product "Basesystem Module 15 SP4 x86_64" + And I open the sub-list of the product "Desktop Applications Module 15 SP4 x86_64" + Then I should see that the "Basesystem Module 15 SP4 x86_64" product is "recommended" + And I should see that the "Server Applications Module 15 SP4 x86_64" product is "recommended" + When I select "SUSE Linux Enterprise Server 15 SP4 x86_64" as a product + Then I should see the "SUSE Linux Enterprise Server 15 SP4 x86_64" selected + And I should see the "Basesystem Module 15 SP4 x86_64" selected + And I should see the "Server Applications Module 15 SP4 x86_64" selected + When I select "Desktop Applications Module 15 SP4 x86_64" as a product + And I select "Development Tools Module 15 SP4 x86_64" as a product + Then I should see the "Desktop Applications Module 15 SP4 x86_64" selected + And I should see the "Development Tools Module 15 SP4 x86_64" selected + When I select "Containers Module 15 SP4 x86_64" as a product + Then I should see the "Containers Module 15 SP4 x86_64" selected + When I click the Add Product button + And I wait until I see "SUSE Linux Enterprise Server 15 SP4 x86_64" product has been added + Then the SLE15 SP4 product should be added + @uyuni Scenario: Add openSUSE Leap 15.5 product, including Uyuni Client Tools When I use spacewalk-common-channel to add channel "opensuse_leap15_5 opensuse_leap15_5-non-oss opensuse_leap15_5-non-oss-updates opensuse_leap15_5-updates opensuse_leap15_5-backports-updates opensuse_leap15_5-sle-updates uyuni-proxy-devel-leap opensuse_leap15_5-uyuni-client" with arch "x86_64" diff --git a/testsuite/features/secondary/buildhost_osimage_build_image.feature b/testsuite/features/secondary/buildhost_osimage_build_image.feature index 2831f3fb4df7..c6950987c0f2 100644 --- a/testsuite/features/secondary/buildhost_osimage_build_image.feature +++ b/testsuite/features/secondary/buildhost_osimage_build_image.feature @@ -26,7 +26,7 @@ Feature: Build OS images And I follow "Create" And I enter "suse_os_image" as "label" And I select "Kiwi" from "imageType" - And I select "1-SUSE-KEY-x86_64" from "activationKey" + And I select "1-TERMINAL-KEY-x86_64" from "activationKey" And I enter the image filename for "pxeboot_minion" relative to profiles as "path" And I click on "create-btn" And I wait until no Salt job is running on "build_host" diff --git a/testsuite/features/secondary/proxy_cobbler_pxeboot.feature b/testsuite/features/secondary/proxy_cobbler_pxeboot.feature index a4868348a314..5dc65a9e0cbe 100644 --- a/testsuite/features/secondary/proxy_cobbler_pxeboot.feature +++ b/testsuite/features/secondary/proxy_cobbler_pxeboot.feature @@ -35,13 +35,12 @@ Feature: PXE boot a terminal with Cobbler And I click on "Apply Highstate" And I wait until event "Apply highstate scheduled by admin" is completed -@susemanager + # We currently test Cobbler with SLES 15 SP4, even on Uyuni Scenario: Install TFTP boot package on the server When I install package tftpboot-installation on the server And I wait for "tftpboot-installation-SLE-15-SP4-x86_64" to be installed on "server" -# TODO: Not available in any Leap repository, yet -# See https://suse.slack.com/archives/C02CKHR76Q2/p1694189245268889 +# TODO: use this code when we start testing Cobbler with Leap #@uyuni # Scenario: Install TFTP boot package on the server # When I install package tftpboot-installation on the server @@ -81,7 +80,7 @@ Feature: PXE boot a terminal with Cobbler When I enter "self_update=0" as "kernel_options" And I click on "Update" And I follow "Variables" - And I enter "distrotree=SLE-15-SP4-TFTP\nregistration_key=1-SUSE-KEY-x86_64\nredhat_management_server=proxy.example.org" as "variables" text area + And I enter "distrotree=SLE-15-SP4-TFTP\nregistration_key=1-TERMINAL-KEY-x86_64\nredhat_management_server=proxy.example.org" as "variables" text area And I click on "Update Variables" And I follow "Autoinstallation File" Then I should see a "SLE-15-SP4-TFTP" text diff --git a/testsuite/features/secondary/proxy_retail_pxeboot_and_mass_import.feature b/testsuite/features/secondary/proxy_retail_pxeboot_and_mass_import.feature index 6c0b94ad3c11..85183dd6d9f6 100644 --- a/testsuite/features/secondary/proxy_retail_pxeboot_and_mass_import.feature +++ b/testsuite/features/secondary/proxy_retail_pxeboot_and_mass_import.feature @@ -320,7 +320,7 @@ Feature: PXE boot a Retail terminal And I disable repositories after installing branch server Scenario: Bootstrap the PXE boot minion - When I create bootstrap script for "proxy.example.org" hostname and set the activation key "1-SUSE-KEY-x86_64" in the bootstrap script on the proxy + When I create bootstrap script for "proxy.example.org" hostname and set the activation key "1-TERMINAL-KEY-x86_64" in the bootstrap script on the proxy And I bootstrap pxeboot minion via bootstrap script on the proxy # Workaround: Increase timeout temporarily get rid of timeout issues And I wait at most 350 seconds until Salt master sees "pxeboot_minion" as "unaccepted"