Skip to content

Commit

Permalink
Trigger reposync of beta tools only when they are published
Browse files Browse the repository at this point in the history
  • Loading branch information
Bischoff committed Feb 7, 2025
1 parent a5b1d7f commit fccf3d9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 3 additions & 2 deletions testsuite/features/reposync/srv_sync_products.feature
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2017-2024 SUSE LLC
# Copyright (c) 2017-2025 SUSE LLC
# Licensed under the terms of the MIT license.

Feature: Synchronize products in the products page of the Setup Wizard
Expand Down Expand Up @@ -66,7 +66,8 @@ Feature: Synchronize products in the products page of the Setup Wizard
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 select "SUSE Linux Enterprise Server LTSS 15 SP4 x86_64" as a product
When I select or deselect "SUSE Manager Client Tools Beta for SLE 15 x86_64 (BETA)" beta client tools
And I select "SUSE Linux Enterprise Server LTSS 15 SP4 x86_64" as a product
Then I should see the "SUSE Linux Enterprise Server LTSS 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
Expand Down
6 changes: 6 additions & 0 deletions testsuite/features/step_definitions/setup_steps.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,12 @@
raise ScriptError, "xpath: #{xpath} not found" unless find(:xpath, xpath).set(select == 'select')
end

When(/^I select or deselect "([^"]*)" beta client tools$/) do |product|
xpath = "//span[contains(text(), '#{product}')]/ancestor::div[contains(@class, 'product-details-wrapper')]/div/input[@type='checkbox']"
product = find(:xpath, xpath)
product.set($beta_enabled) if product
end

When(/^I wait at most (\d+) seconds until the tree item "([^"]+)" has no sub-list$/) do |timeout, item|
repeat_until_timeout(timeout: timeout.to_i, message: "could still find a sub list for tree item #{item}") do
xpath = "//span[contains(text(), '#{item}')]/ancestor::div[contains(@class, 'product-details-wrapper')]/div/i[contains(@class, 'fa-angle-')]"
Expand Down

0 comments on commit fccf3d9

Please sign in to comment.