check, checklist, api, request, response, send, soap, rest, get, post, put, delete

Method CheckResponseByList

API

Checks response by list (CheckList) where "Path" is the path to the property and "Value" is comparable value

Watch this video to learn how to use this method

Have a problem with playback?
Method option CheckResponseByList. Prior to use this one you need to insert Execute method. CheckResponseByList checks if the output result contains expected data located in the check list. The checklist contains path and value - please refer separate Checklist video for detailed explanation of these parameters. The boolean output of CheckResponseByList is True if response matches the checklist data or False if response not matches the checklist data. With the messagebox we can validate the output of method. Here's how response looks like We can see output is True means the response matches the checklist The sum of the Execute and CheckResponseByList is method ExecuteAndCheckResponseByList It sends the API request, validates it is correctly accepted by server and checks if the output result contains expected data located in the check list. It returns True if request successfull and response matches the checklist data Returns False in any other case. Let's try it. As before we output result to the messagebox. You can see that method been executed successfully and response is correct.

Usage

Function CheckResponseByList( 
    Boolean Report [Optional]
)

Method

CheckResp...

True

Report

Parameters

Report (optional)

Type: Boolean

Default value: True

Report Result

Returns

True if equal

Example

VBScript

Server("API Server").Method("Method").CheckResponseByList
' Set Report parameter
Server("API Server").Method("Method").CheckResponseByList True

JavaScript

Server("API Server").Method("Method").CheckResponseByList();
// Set Report parameter
Server("API Server").Method("Method").CheckResponseByList(true);

Method

CheckResp...

Comment

Set Report parameter

Method

CheckResp...

True

Contact Us

Tower Place 100

3340 Peachtree Rd NE #1800 

Atlanta, GA 30326 USA

(404) 814-5227