Commit 3e3f32f5 authored by Afonso Castanheta's avatar Afonso Castanheta
Browse files

Fix: update the CAPIF_USERS dictionary after Update Onboarded Network App Certificate test

parent fed8abaa
Loading
Loading
Loading
Loading
Loading
+2 −23
Original line number Diff line number Diff line
@@ -183,29 +183,8 @@ Update Onboarded Network App Certificate
    Check Response Variable Type And Values    ${resp}    200    APIInvokerEnrolmentDetails
    ...    notificationDestination=${new_notification_destination}

    #Revert to old invoker username and certificate
    ${csr_request_old}=    Create User Csr    ${INVOKER_USERNAME}    invoker

    ${old_onboarding_notification_body}=    Create Onboarding Notification Body
    ...    http://${CAPIF_CALLBACK_IP}:${CAPIF_CALLBACK_PORT}/netapp_callback
    ...    ${csr_request_old}
    ...    ${INVOKER_USERNAME_NEW}

    Set To Dictionary
    ...    ${request_body}
    ...    onboardingInformation=${old_onboarding_notification_body['onboardingInformation']}

    ${resp}=    Put Request Capif
    ...    ${url.path}
    ...    ${request_body}
    ...    server=${CAPIF_HTTPS_URL}
    ...    verify=ca.crt
    ...    username=${INVOKER_USERNAME_NEW}

    Check Response Variable Type And Values    ${resp}    200    APIInvokerEnrolmentDetails

    Store In File    ${INVOKER_USERNAME}.crt    ${resp.json()['onboardingInformation']['apiInvokerCertificate']}
    
    # Update CAPIF_USERS to use the NEW certificate name for cleanup
    Call Method    ${CAPIF_USERS}    update_capif_users_dicts    ${url.path}    ${INVOKER_USERNAME_NEW}

Onboard invoker without supported_features
    [Tags]    capif_api_invoker_management-8