Parameterize base url, api path and other details

34 views
Skip to first unread message

mahadev swamy

unread,
Feb 8, 2022, 10:49:44 AM2/8/22
to gat...@googlegroups.com
Hi Team,

From the JSON payload, i want to get base URL, api path and other details to simulation code. 

JSON file.

along with JSON payload data, i want to take basepath also from json file to simulation class. not able to achieve this. Please help.

Thanks.

{
"test_name": "Minimal Redis performance test",
"method": "POST",
"basePath": "http://reqres.in",
"path": "api/users",
"data":
{
"name": "morphus",
"job": "leader"
}
}

Simulation file
class simulation extends Simulation {
private val basePath = "http://reqres.in"
private val apiPath = "/api/users"
private val POST = "POST"
Reply all
Reply to author
Forward
0 new messages