File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -326,6 +326,17 @@ The `request` object is a mandatory part of an URL monitor.
326
326
- ` skipSSL ` : A boolean indicating whether to skip validation of SSL certificates.
327
327
- ` assertions ` : You can define assertions via the ` UrlAssertionBuilder ` . For URL monitors, only status code assertions are supported. For example:
328
328
329
+ ### ` UrlAssertionBuilder `
330
+
331
+ To define ` assertions ` for the ` request ` of an ` UrlMonitor ` you should use the ` UrlAssertionBuilder ` . The ` UrlAssertionBuilder `
332
+ has the following properties:
333
+
334
+ - ` statusCode() ` : Assert the HTTP status code for the HTTP response, e.g. ` 200 ` or ` 201 ` .
335
+
336
+ Here is an example:
337
+
338
+ - Assert the status code of a HTTP request
339
+
329
340
``` ts
330
341
UrlAssertionBuilder .statusCode ().equals (200 )
331
342
// renders to a JSON string
You can’t perform that action at this time.
0 commit comments