Gatling save response in html redirect

given this response I want to save the value of “href”.

  <li class="list-group-item">
        <a id="Test IDP" class="ln-List_Element" tabindex="(3" title="Velg Test IDP" href="/Account/ExternalLogin?provider=testidp-oidc&amp;returnUrl=%2Fconnect%2Fauthorize%2Fcallback%3FauthzId%3D29107B505672D5E805F20347833D87F75116C5DC499E0693CBF5F48F2BCDFEC3">
            <div>
                    <span class="ln-List_Element_Logo">
                        <img src="/img/test-idp.png" alt="Test IDP">
                    </span>
            </div>

            <div class="ln-List_Element_Service">
                <span class="ln-List_Element_Service_Name">Test IDP</span>
                    <span class="ln-List_Element_Service_Info">Logg inn med en fiktiv bruker i v&#xE5;r Test IDP. Bare tilgjengelig i testmilj&#xF8;er.</span>
            </div>
        </a>

    </li>

I think the css-selector would be a good match, but not sure how to construct the xpression. i.e.

.check(css(“#Test IDP”,“href”).saveAs(“idp”))

html element id cannot contain space.

Cheers

1 Like