Can I write assertions for the Artillery Load Test results?
1 answer
You can do it with javascript.
In artillery script, use afterResponce: and write your confirmation code there.
"get": {"url": "host/path",
"headers": {
"Content-Type":"application/json"
},
"afterResponse": "function_name"
}
write function_name in a separate js file and add a statement to that function.
Import this js file into your artillery script as shown below
"processor": "./my_function.js"
+1
source to share