Skip to content

Commit

Permalink
QE: Improve how we wait for each product to be synchronized
Browse files Browse the repository at this point in the history
  • Loading branch information
srbarrios committed Aug 25, 2023
1 parent d17c127 commit fc3dbe1
Show file tree
Hide file tree
Showing 5 changed files with 398 additions and 195 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
Then I should see the "SUSE Linux Enterprise Server LTSS 12 SP4 x86_64" selected
When I click the Add Product button
And I wait until I see "SUSE Linux Enterprise Server 12 SP4 x86_64" product has been added
And I wait until all synchronized channels for "sles12-sp4" have finished

@sle12sp5_minion
Scenario: Add SUSE Linux Enterprise Server 12 SP5
Expand All @@ -31,6 +32,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
Then I should see the "SUSE Linux Enterprise Server 12 SP5 x86_64" selected
When I click the Add Product button
And I wait until I see "SUSE Linux Enterprise Server 12 SP5 x86_64" product has been added
And I wait until all synchronized channels for "sles12-sp5" have finished

@sle15sp1_minion
Scenario: Add SUSE Linux Enterprise Server 15 SP1
Expand All @@ -44,6 +46,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
Then I should see the "SUSE Linux Enterprise Server LTSS 15 SP1 x86_64" selected
When I click the Add Product button
And I wait until I see "SUSE Linux Enterprise Server 15 SP1 x86_64" product has been added
And I wait until all synchronized channels for "sles15-sp1" have finished

@sle15sp2_minion
Scenario: Add SUSE Linux Enterprise Server 15 SP2
Expand All @@ -63,6 +66,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
Then I should see the "Development Tools Module 15 SP2 x86_64" selected
When I click the Add Product button
And I wait until I see "SUSE Linux Enterprise Server 15 SP2 x86_64" product has been added
And I wait until all synchronized channels for "sles15-sp2" have finished

@sle15sp3_minion
Scenario: Add SUSE Linux Enterprise Server 15 SP3
Expand All @@ -83,6 +87,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Server 15 SP3 x86_64" product has been added
And I wait until all synchronized channels for "sles15-sp3" have finished

@sle15sp4_minion
Scenario: Add SUSE Linux Enterprise Server 15 SP4
Expand All @@ -101,24 +106,26 @@ Feature: Synchronize products in the products page of the Setup Wizard
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Server 15 SP4 x86_64" product has been added
And I wait until all synchronized channels for "sles15-sp4" have finished

@sle15sp5_minion
Scenario: Add SUSE Linux Enterprise Server 15 SP5
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 SP5" as the filtered product description
And I select "SUSE Linux Enterprise Server 15 SP5 x86_64" as a product
Then I should see the "SUSE Linux Enterprise Server 15 SP5 x86_64" selected
When I open the sub-list of the product "SUSE Linux Enterprise Server 15 SP5 x86_64"
And I open the sub-list of the product "Basesystem Module 15 SP5 x86_64"
And I select "Desktop Applications Module 15 SP5 x86_64" as a product
Then I should see the "Desktop Applications Module 15 SP5 x86_64" selected
When I open the sub-list of the product "Desktop Applications Module 15 SP5 x86_64"
And I select "Development Tools Module 15 SP5 x86_64" as a product
Then I should see the "Development Tools Module 15 SP5 x86_64" selected
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Server 15 SP5 x86_64" product has been added
Scenario: Add SUSE Linux Enterprise Server 15 SP5
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 SP5" as the filtered product description
And I select "SUSE Linux Enterprise Server 15 SP5 x86_64" as a product
Then I should see the "SUSE Linux Enterprise Server 15 SP5 x86_64" selected
When I open the sub-list of the product "SUSE Linux Enterprise Server 15 SP5 x86_64"
And I open the sub-list of the product "Basesystem Module 15 SP5 x86_64"
And I select "Desktop Applications Module 15 SP5 x86_64" as a product
Then I should see the "Desktop Applications Module 15 SP5 x86_64" selected
When I open the sub-list of the product "Desktop Applications Module 15 SP5 x86_64"
And I select "Development Tools Module 15 SP5 x86_64" as a product
Then I should see the "Development Tools Module 15 SP5 x86_64" selected
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Server 15 SP5 x86_64" product has been added
And I wait until all synchronized channels for "sles15-sp5" have finished

@slemicro51_minion
Scenario: Add SUSE Linux Enterprise Micro 5.1
Expand All @@ -133,6 +140,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Micro 5.1 x86_64" product has been added
And I wait until all synchronized channels for "suse-microos-5.1" have finished

@slemicro52_minion
Scenario: Add SUSE Linux Enterprise Micro 5.2
Expand All @@ -147,6 +155,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Micro 5.2 x86_64" product has been added
And I wait until all synchronized channels for "suse-microos-5.2" have finished

@slemicro53_minion
Scenario: Add SUSE Linux Enterprise Micro 5.3
Expand All @@ -161,6 +170,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Micro 5.3 x86_64" product has been added
And I wait until all synchronized channels for "sle-micro-5.3" have finished

@slemicro54_minion
Scenario: Add SUSE Linux Enterprise Micro 5.4
Expand All @@ -175,6 +185,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Linux Enterprise Micro 5.4 x86_64" product has been added
And I wait until all synchronized channels for "sle-micro-5.4" have finished

@opensuse154arm_minion
Scenario: Add openSUSE 15.4 for ARM
Expand All @@ -186,6 +197,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "openSUSE Leap 15.4 aarch64" product has been added
And I wait until all synchronized channels for "leap15.4-aarch64" have finished

@opensuse155arm_minion
Scenario: Add openSUSE 15.5 for ARM
Expand All @@ -197,6 +209,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "openSUSE Leap 15.5 aarch64" product has been added
And I wait until all synchronized channels for "leap15.5-aarch64" have finished

@alma9_minion
Scenario: Add Alma Linux 9
Expand All @@ -207,6 +220,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "AlmaLinux 9 x86_64" selected
When I click the Add Product button
And I wait until I see "AlmaLinux 9 x86_64" product has been added
And I wait until all synchronized channels for "almalinux9" have finished

@centos7_minion
Scenario: Add SUSE Linux Enterprise Server with Expanded Support 7
Expand All @@ -217,21 +231,32 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "SUSE Linux Enterprise Server with Expanded Support 7" selected
When I click the Add Product button
And I wait until I see "SUSE Linux Enterprise Server with Expanded Support 7" product has been added
And I wait until all synchronized channels for "res7" have finished

@liberty9_minion
Scenario: Add Liberty Linux 9
@rhel9_minion
Scenario: Add RHEL 9
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "Loading" text
And I enter "RHEL and Liberty 9 Base" as the filtered product description
And I select "RHEL and Liberty 9 Base" as a product
Then I should see the "RHEL and Liberty 9 Base" selected
When I click the Add Product button
And I wait until I see "RHEL and Liberty 9 Base" product has been added
And I wait until all synchronized channels for "el9" have finished

@liberty9_minion
Scenario: Add Liberty Linux 9
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "Loading" text
And I enter "RHEL and Liberty 9 Base" as the filtered product description
And I select "RHEL and Liberty 9 Base" as a product
Then I should see the "RHEL and Liberty 9 Base" selected
When I open the sub-list of the product "RHEL and Liberty 9 Base"
And I select "SUSE Liberty Linux 9" as a product
Then I should see the "SUSE Liberty Linux 9" selected
When I click the Add Product button
And I wait until I see "SUSE Liberty Linux 9" product has been added
And I wait until all synchronized channels for "sll-9" have finished

@oracle9_minion
Scenario: Add Oracle Linux 9
Expand All @@ -242,16 +267,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "Oracle Linux 9 x86_64" selected
When I click the Add Product button
And I wait until I see "Oracle Linux 9 x86_64" product has been added

@rhel9_minion
Scenario: Add RHEL 9
When I follow the left menu "Admin > Setup Wizard > Products"
And I wait until I do not see "Loading" text
And I enter "RHEL and Liberty 9 Base" as the filtered product description
And I select "RHEL and Liberty 9 Base" as a product
Then I should see the "RHEL and Liberty 9 Base" selected
When I click the Add Product button
And I wait until I see "RHEL and Liberty 9 Base" product has been added
And I wait until all synchronized channels for "oraclelinux9" have finished

@rocky8_minion
Scenario: Add SUSE Linux Enterprise Server with Expanded Support 8
Expand All @@ -265,6 +281,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "SUSE Linux Enterprise Server with Expanded Support 8" selected
When I click the Add Product button
And I wait until I see "RHEL or SLES ES or CentOS 8 Base" product has been added
And I wait until all synchronized channels for "res8" have finished

@rocky9_minion
Scenario: Add Rocky Linux 9
Expand All @@ -275,6 +292,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "Rocky Linux 9 x86_64" selected
When I click the Add Product button
And I wait until I see "Rocky Linux 9 x86_64" product has been added
And I wait until all synchronized channels for "rockylinux-9" have finished

@ubuntu1804_minion
Scenario: Add Ubuntu 18.04
Expand All @@ -295,6 +313,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "Ubuntu 20.04" selected
When I click the Add Product button
And I wait until I see "Ubuntu 20.04" product has been added
And I wait until all synchronized channels for "ubuntu-2004" have finished

@ubuntu2204_minion
Scenario: Add Ubuntu 22.04
Expand All @@ -305,6 +324,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "Ubuntu 22.04" selected
When I click the Add Product button
And I wait until I see "Ubuntu 22.04" product has been added
And I wait until all synchronized channels for "ubuntu-2204" have finished

@debian10_minion
Scenario: Add Debian 10
Expand All @@ -315,6 +335,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
Then I should see the "Debian 10" selected
When I click the Add Product button
And I wait until I see "Debian 10" product has been added
And I wait until all synchronized channels for "debian-10" have finished

@debian11_minion
Scenario: Add Debian 11
Expand All @@ -324,7 +345,8 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
And I select "Debian 11" as a product
Then I should see the "Debian 11" selected
When I click the Add Product button
And I wait until I see "Debian 11" product has been added
And I wait until I see "Debian 11" product has been added
And I wait until all synchronized channels for "debian-11" have finished

@proxy
Scenario: Add SUSE Manager Proxy 4.3
Expand All @@ -336,6 +358,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Manager Proxy 4.3 x86_64" product has been added
And I wait until all synchronized channels for "suma-proxy-43" have finished

@proxy
Scenario: Add SUSE Manager Retail Branch Server 4.3
Expand All @@ -347,6 +370,7 @@ Scenario: Add SUSE Linux Enterprise Server 15 SP5
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Manager Retail Branch Server 4.3 x86_64" product has been added
And I wait until all synchronized channels for "suma-retail-branch-server-43" have finished

Scenario: Detect product loading issues from the UI in Build Validation
When I follow the left menu "Admin > Setup Wizard > Products"
Expand Down
4 changes: 4 additions & 0 deletions testsuite/features/reposync/srv_sync_products.feature
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,12 @@ Feature: Synchronize products in the products page of the Setup Wizard
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
When I wait until all synchronized channels for "sles15-sp4" have finished

@uyuni
Scenario: Add openSUSE Leap 15.4 product, including Uyuni Client Tools
When I use spacewalk-common-channel to add channel "opensuse_leap15_4 opensuse_leap15_4-non-oss opensuse_leap15_4-non-oss-updates opensuse_leap15_4-updates opensuse_leap15_4-backports-updates opensuse_leap15_4-sle-updates uyuni-proxy-devel-leap opensuse_leap15_4-uyuni-client" with arch "x86_64"
And I wait until all synchronized channels for "leap15.4-x86_64" have finished

@proxy
@susemanager
Expand All @@ -77,6 +79,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Manager Proxy 4.3 x86_64" product has been added
And I wait until all synchronized channels for "suma-proxy-43" have finished

@proxy
@susemanager
Expand All @@ -89,6 +92,7 @@ Feature: Synchronize products in the products page of the Setup Wizard
When I click the Add Product button
And I wait until I see "Selected channels/products were scheduled successfully for syncing." text
And I wait until I see "SUSE Manager Retail Branch Server 4.3 x86_64" product has been added
And I wait until all synchronized channels for "suma-retail-branch-server-43" have finished

@scc_credentials
@susemanager
Expand Down
7 changes: 7 additions & 0 deletions testsuite/features/step_definitions/command_steps.rb
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,13 @@
end
end

When(/I wait until all synchronized channels for "([^"]*)" have finished$/) do |product_os_version|
CHANNEL_TO_SYNCH_BY_OS_PRODUCT_VERSION[product_os_version].each do |channel|
log "I wait until '#{channel}' synchronized channel has finished"
step %(I wait until the channel "#{channel}" has been synced)
end
end

When(/^I execute mgr\-bootstrap "([^"]*)"$/) do |arg1|
$command_output, _code = get_target('server').run("mgr-bootstrap #{arg1}")
end
Expand Down
9 changes: 5 additions & 4 deletions testsuite/features/support/commonlib.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,20 @@ def compute_channels_to_leave_running
# keep the repos needed for the auto-installation tests
do_not_kill =
if product == 'Uyuni'
CHANNEL_TO_SYNCH_BY_OS_VERSION['15.4']
CHANNEL_TO_SYNCH_BY_OS_PRODUCT_VERSION['sles15-sp4']
else
CHANNEL_TO_SYNCH_BY_OS_VERSION['default']
CHANNEL_TO_SYNCH_BY_OS_PRODUCT_VERSION['default']
end
[get_target('sle_minion'), get_target('build_host'), get_target('ssh_minion'), get_target('rhlike_minion')].each do |node|
next unless node
os_version = node.os_version
os_family = node.os_family
next unless ['sles', 'rocky'].include?(os_family)
os_version = os_version.split('.')[0] if os_family == 'rocky'
log 'Can\'t build list of reposyncs to leave running' unless %w[15-SP3 15-SP4 15.4 8].include? os_version
do_not_kill += CHANNEL_TO_SYNCH_BY_OS_VERSION[os_version]
log 'Can\'t build list of reposyncs to leave running' unless %w[sles15-sp3 sles15-sp4 leap15.4-x86_64 res8].include? os_version
do_not_kill += CHANNEL_TO_SYNCH_BY_OS_PRODUCT_VERSION[os_version]
end
do_not_kill += CHANNEL_TO_SYNCH_BY_OS_PRODUCT_VERSION['fake'] unless $build_validation
do_not_kill.uniq
end

Expand Down
Loading

0 comments on commit fc3dbe1

Please sign in to comment.