diff --git a/tests/foreman/ui/test_activationkey.py b/tests/foreman/ui/test_activationkey.py index 04546d9ba76..68e155bd48b 100644 --- a/tests/foreman/ui/test_activationkey.py +++ b/tests/foreman/ui/test_activationkey.py @@ -1229,3 +1229,22 @@ def test_positive_ak_with_custom_product_on_rhel6(session, rhel6_contenthost, ta ak = session.activationkey.read(ak.name, widget_names='content_hosts') assert len(ak['content_hosts']['table']) == 1 assert ak['content_hosts']['table'][0]['Name'] == rhel6_contenthost.hostname + + +def test_positive_prepare_for_sca_only_ak(target_sat, function_entitlement_manifest_org): + """Verify that the ActivationKey details page notifies users that Simple Content Access + will be required for all organizations in Satellite 6.16 + + :id: 417a8331-3c66-473f-938c-bbf01deb6031 + + :expectedresults: The ActivationKey page notifies users that Simple Content Access will + be required for all organizations in Satellite 6.16 + """ + ak = target_sat.api.ActivationKey(organization=function_entitlement_manifest_org).create() + with target_sat.ui_session() as session: + session.organization.select(function_entitlement_manifest_org.name) + ak = session.activationkey.read(ak.name) + assert ( + 'This organization is not using Simple Content Access. Entitlement-based subscription management is deprecated and will be removed in Katello 4.12.' + in ak['sca_alert'] + ) diff --git a/tests/foreman/ui/test_organization.py b/tests/foreman/ui/test_organization.py index 460e2ab38a7..753f28e7a5c 100644 --- a/tests/foreman/ui/test_organization.py +++ b/tests/foreman/ui/test_organization.py @@ -362,3 +362,23 @@ def test_positive_product_view_organization_switch(session, module_org, module_p assert session.product.search(module_product.name) session.organization.select(org_name="Default Organization") assert not session.product.search(module_product.name) == module_product.name + + +def test_positive_prepare_for_sca_only_organization(target_sat, function_entitlement_manifest_org): + """Verify that the organization details page notifies users that Simple Content Access + will be required for all organizations in Satellite 6.16 + + :id: 3a6a848b-3c16-4dbb-8f52-5ea57a9a97ef + + :expectedresults: The Organization details page notifies users that Simple Content Access will + be required for all organizations in Satellite 6.16 + """ + with target_sat.ui_session() as session: + session.organization.select(function_entitlement_manifest_org.name) + sca_alert = session.organization.read( + function_entitlement_manifest_org.name, widget_names='primary' + ) + assert ( + 'Simple Content Access will be required for all organizations in Katello 4.12.' + in sca_alert['primary']['sca_alert'] + ) diff --git a/tests/foreman/ui/test_subscription.py b/tests/foreman/ui/test_subscription.py index 2196eabb60b..de2c60d62d7 100644 --- a/tests/foreman/ui/test_subscription.py +++ b/tests/foreman/ui/test_subscription.py @@ -551,3 +551,21 @@ def test_positive_candlepin_events_processed_by_STOMP( response = entities.Ping().search_json()['services']['candlepin_events'] assert response['status'] == 'ok' assert '0 Failed' in response['message'] + + +def test_positive_prepare_for_sca_only_subscription(target_sat, function_entitlement_manifest_org): + """Verify that the Subcsription page notifies users that Simple Content Access + will be required for all organizations in Satellite 6.16 + + :id: cb6fdfdd-04ee-4acb-9460-c78556cef11e + + :expectedresults: The Subscription page notifies users that Simple Content Access will + be required for all organizations in Satellite 6.16 + """ + with target_sat.ui_session() as session: + session.organization.select(function_entitlement_manifest_org.name) + sca_alert = session.subscription.sca_alert() + assert ( + 'This organization is not using Simple Content Access. Entitlement-based subscription management is deprecated and will be removed in Katello 4.12.' + in sca_alert + )