Skip to main content

Assert Suite

This section will provide you withprovides the current execution results so you can add custom assertions to your scenario,scenario. there are severalSeveral assertion types are available from the assertAssert typeType drop-down menu, and some assertions are exclusively for requests. For most assertions, the AIQ UI will provide you withprovides current resultsresult informationinformation, so you don’don't have to findlook outup the current results to validate against. These are the available assertions:

  • Assert Exists: Validates whether or not the target element exists in the results tree.

    Assert Size: Validates the actual size of the desired target against the given custom value. Comparison criteria can be set to: equals, not equals, less than, moregreater than, less than or equal, moregreater than or equal.

      Assert Duration: Validates the actual duration of the desired target against the given custom value. Comparison criteria can be set to: equals, not equals, less than, moregreater than, less than or equal, moregreater than or equal.

        Assert Matches (Request only): Compares athe request-response content to validate ifwhether the given baseline string is contained in the request-responseresponse, delimited by the given target accessor. The userYou must know and specify the request-response content format,format. The target accessor field changes according to the response format,format:

        if
          If the response format is plain text, use regular expressions to limit the response range to what is valid (using “".*”" will validatevalidates against the whole response),. ifIf the response format is JSON thenJSON, provide the JSON path to the desired element to assert,assert. ifIf the response format is XMLXML, provide the XPath to the desired tag,tag. the

          The only available formats that AIQ can handle so far for this proceduresprocedure are: text, JSONJSON, and XML.

            Assert Checksum (Request only): Validates the actual request-response checksum against the given custom checksum.

              Assert Response Code (Request only): Validates the actual request request-response code against the given custom response code.

                Store Content: The very first thing to know about this is that it is NOT an assertion,assertion; thisit is an auxiliary function of AIQ whichthat provides the user with the ability to store request-response content into an internal custom-named variable in The Locker, which can be used onin a furtherlater request if required. For example, imagine you have a shopping cart web application,application. oneOne of your requests generates a unique ID number associated with each cart,cart. let’Let's assume that this number is required to process transactions,transactions. underIn this context, you could store the first request response (the ID) and then instruct AIQ to use it at the expected requestrequest, taking the value from the stored content.

                AI Assert

                AIQ also offers AI Assert, a Web Designer capability that lets you validate any visual, motion, or text-based outcome on screen simply by describing it in natural language, across web and mobile applications.

                For more information, see AIQ AI ASSERT - Next-Generation UI Testing.


                Last updated: February 17, 2023

                If you have any feedback on this topic, please contact us at documentation@appvance.ai