fbpx

Method CheckHeaderValue

Checks Header with a Given value

Usage

Function CheckHeaderValue(
    String HeaderName,
    String Value,
    Boolean Report [Optional]
)

Parameters

HeaderName

Type: String

Header Name

Value

Type: String

Value

Report (optional)

Type: Boolean

Default value: True

Report Result

Returns

True if header value matches value parameter

Example

VBScript

Server("API Server").Method("Method").Execute
' Execute method should be called before check header value
headerValue = Server("API Server").Method("Method").CheckHeaderValue("Server", "Apache/2.4.1")

JavaScript

Server("API Server").Method("Method").Execute();
// Execute method should be called before check header value
var headerValue = Server("API Server").Method("Method").CheckHeaderValue("Server", "Apache/2.4.1");

Documentation Categories

ZAPTEST

FARM

LOAD

Virtual Expert

ZAPTEST

ZAPTEST Logo