From 7b5aa5f8eaba36eada44cd2fe0cd0fd2dd57427a Mon Sep 17 00:00:00 2001 From: Jeremy Lenz Date: Wed, 14 Feb 2024 13:53:39 -0500 Subject: [PATCH] Fixes #34044 - stop caring about array order in test_sync_container_gateway (#10889) (cherry picked from commit 1b9a08b7596c30a97ccb1b602094576e7c3c4b01) --- test/models/concerns/smart_proxy_extensions_test.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/test/models/concerns/smart_proxy_extensions_test.rb b/test/models/concerns/smart_proxy_extensions_test.rb index 2000f82371f..35419440a79 100644 --- a/test/models/concerns/smart_proxy_extensions_test.rb +++ b/test/models/concerns/smart_proxy_extensions_test.rb @@ -248,9 +248,12 @@ def test_sync_container_gateway with_pulp3_features(capsule_content.smart_proxy) capsule_content.smart_proxy.add_lifecycle_environment(environment) - repo_list_update_expectation = ProxyAPI::ContainerGateway.any_instance.expects(:repository_list).with( + expected_repo_list_args = { :repositories => [{:repository => "empty_organization-puppet_product-busybox", :auth_required => true}, {:repository => "busybox", :auth_required => true}] - ) + } + repo_list_update_expectation = ProxyAPI::ContainerGateway.any_instance.expects(:repository_list).with do |value| + Set.new(value[:repositories]) == Set.new(expected_repo_list_args[:repositories]) + end repo_list_update_expectation.once.returns(true) repo_mapping_update_expectation = ProxyAPI::ContainerGateway.any_instance.expects(:user_repository_mapping).with do |arg|